__STDC__ and non-strictly conforming ANSI C compilers

Doug Gwyn gwyn at smoke.BRL.MIL
Fri Dec 16 06:39:57 AEST 1988


In article <8366 at megaron.arizona.edu> gmt at arizona.edu (Gregg Townsend) writes:
>I agree that compilers shouldn't break programs by adding gratuitous
>extensions.  But if they do, undefining __STDC__ won't help.

Sure it will.  I certainly want to hear about it if my use of a
function asm(char*) conflicts with a vendor extension!  __STDC__
is defined as meaning "complies with the standard", and I want to
be able to be warned when the "" phrase does NOT apply -- no matter
WHAT the reason.
	#if !STDC__
	#include "*** ERROR *** This program requires real ANSI C"
	#endif



More information about the Comp.std.c mailing list