sensiblehue <sensible...@firemail.cc> wrote: > On Thu, Jun 11, 2020 at 03:08:01PM +0200, Marc Espie wrote: > > On Thu, Jun 11, 2020 at 04:37:34AM +0000, sensiblehue wrote: > > > Hello, > > > I was wondering why OpenBSD doesn't have a `__printflike' macro in > > > <sys/cdefs.h>? FreeBSD, NetBSD, and DragonflyBSD have it and it's also > > > available from libbsd on Linux. > > > Personally I think it's cleaner and just as portable if not more > > > portable, because some compilers don't support `__attribute__'. > > > > > > What compilers ? > > GCC < v2.5 and non GNU C compilers, though I see now that OpenBSD > defines it to nothing in that case.
Ah, so it does actually work fine, unlike what you originally claimed. > To be honest I'm mostly suggesting __printflike because I want to use it > in my own code and still have it compile on OpenBSD without an #ifdef, > but it would also make software from other BSDs easier to port. We are using the attribute mechanism directly in a way that works on all modern (10 years?). Intentionally. Your proposal requires everyone to eventually have a new cpp symbol. You start by requiring us to have the symbol, then you'll go after the next people? Why are you asking us before you ask Microsoft?