This is the mail archive of the mailing list for the glibc project.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: Don't check __GNUC__ together with __USE_EXTERN_INLINES

On Tue, Jan 08, 2013 at 01:54:58PM +0000, Joseph S. Myers wrote:
> Two places in glibc's installed headers use a condition defined
> __GNUC__ && __GNUC__ >= 2 && defined __USE_EXTERN_INLINES.  This is
> redundant, since __USE_EXTERN_INLINES is only defined if __GNUC_PREREQ
> (2, 7).  (Logically such a combination could make sense of a sort *if*
> the inline functions used some other extension, beyond
> __extern_inline, but they don't, other than through macros that
> sys/cdefs.h defines to empty for compilers not supporting them.)
> This patch accordingly changes those conditionals to test just the
> logical feature macro __USE_EXTERN_INLINES, and not the GCC version.
> Tested x86_64.

There are a couple of places where __USE_EXTERN_INLINES is explicitly
set, for example in argp/argp-xinl.h.  The patch could break such code
if it includes any of the headers you've changed after explcitly
setting __USE_EXTERN_INLINES.  If you've verified that these cases
don't break then the change should be safe.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]