Article View: comp.std.c
Article #2453Want the word on __STDC__
From: David Fenyes
Date: Tue, 19 Feb 1991 23:22
Date: Tue, 19 Feb 1991 23:22
28 lines
1567 bytes
1567 bytes
Hello, Here's the question: Everybody knows that ANSI C compilers with ANSI preprocessors should have __STDC__ #defined to 1, and K&R compilers with K&R cpp don't have __STDC__ #defined at all. The question is: Does an ANSI cpp ALWAYS #define __STDC__, even if it is used intentionally with a K&R compiler (#defined to 0)? Mark Williams uses an ANSI cpp with their non-ANSI compiler, and #defines __STDC__ to 0, which causes all sorts of problems when code tests #ifdef __STDC__ . . . (rather than #if __STDC__). Who is the offender? MWC, or those #ifdef'ers out there? It makes sense to #define __STDC__ so the code can take advantage of the ANSI cpp features, while still not using ANSI prototypes, etc. If anyone knows the answer from the ANSI documents, please let me know, or post to the net. I'd be glad to summarize any info mailed to me for the net. Thanks, David. -- David Fenyes dfenyes@thesis1.hsch.utexas.edu University of Texas Medical School Houston, Texas
Technical Details
Message-ID:
<4755@lib.tmc.edu>Path:
arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!rutgers!usc!zaphod.mps.ohio-state.edu!wuarchive!rice!bcm!lib!thesis1.hsch.utexas.eduShow Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!rutgers!usc!zaphod.mps.ohio-state.edu!wuarchive!rice!bcm!lib!thesis1.hsch.utexas.edu From: dfenyes@thesis1.hsch.utexas.edu (David Fenyes) Newsgroups: comp.std.c Subject: Want the word on __STDC__ Keywords: ANSI C __STDC__ preprocessor Message-ID: <4755@lib.tmc.edu> Date: 19 Feb 91 23:22:16 GMT Sender: usenet@lib.tmc.edu Distribution: usa Organization: University of Texas Medical School at Houston Lines: 28 Nntp-Posting-Host: thesis1.hsch.utexas.edu