FE_* constants and ISO C99

Jakub Jelinek jakub@redhat.com
Mon Jun 25 03:37:00 GMT 2001


Hi!

ISO C99 states in 7.1.4.1:
All object-like macros listed as expanding to integer constant expressions
shall additionally be suitable for use in #if preprocessing directives.

I'm not entirely sure if this allows them to be defined as they sometimes
are in glibc headers, ie.
enum { 
  FE_INEXACT = 0x??
#define FE_INEXACT FE_INEXACT
};
, see http://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=44520
because they can then be only used in #if preprocessing directives when
testing if they are defined, not to check their value (and I don't see why
ISO C99 would explicitely state it when all macros are suitable for use in
#ifdef resp #if defined() preprocessing directives).
Ideas?

	Jakub



More information about the Libc-hacker mailing list