Path: utzoo!attcan!uunet!lll-winken!ames!mailrus!cornell!uw-beaver!microsoft!w-colinp From: w-colinp@microsoft.UUCP (Colin Plumb) Newsgroups: comp.std.c Subject: Re: __STDC__ and non-conforming ANSI C compilers Message-ID: <264@microsoft.UUCP> Date: 14 Jan 89 00:41:06 GMT References: <898@ubu.warwick.UUCP> Reply-To: w-colinp@microsoft.uucp (Colin Plumb) Organization: very little Lines: 21 Disclaimer: I have absolutely *nothing* to do with the people writing the Microsoft C compiler. This is a more general statement. Personally, I generally thing setting __STDC__ to 0 if a compiler almost makes it, but will parse ANSI C programs and, for the most part, compile them, is a Good Thing. It's not in violation of the standard, because the standard requires that __STDC__ set to 1. #if __STDC__ == 1 is the way to *really* test for the strictest ANSI compliance. But in 90% of the cases, it *does* handle all that code people are writing that basically has #ifdef __STDC__ /* prototype function declarations and macros using # and ## */ #else /* old style declarations and macros using in-string replacement and /**/ */ #endif as the author "intended". -- -Colin (uunet!microsof!w-colinp)