On 2011-07-04 18:30, Robert Millan wrote:
This patch fixes a (harmless) warning when<sys/cdefs.h>  is parsed by
upstream version of GCC.

-#if __FreeBSD_cc_version >= 300001 && defined(__GNUC__) && 
!defined(__INTEL_COMPILER)
+#if defined(__FreeBSD_cc_version) && __FreeBSD_cc_version >= 300001 && 
defined(__GNUC__) && !defined(__INTEL_COMPILER)

As far as I can see, this code only gives warnings when compiled with
gcc 4.5 or higher, and when using the -Wundef flag.  Isn't it easier to
just remove the -Wundef flag here?

Additionally, it looks like the C standard is a bit vague about whether
the preprocessor uses short-circuited boolean evaluation (although gcc's
manual says it does), so I'm not sure whether this patch solves the
problem properly either.
_______________________________________________
freebsd-hackers@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-hackers
To unsubscribe, send any mail to "freebsd-hackers-unsubscr...@freebsd.org"

Reply via email to