steven@cwi.nl (Steven Pemberton) (05/17/89)
In article <431fba10.14a1f@gtephx.UUCP> covertr@gtephx.UUCP (Richard E. Covert) writes: > I am still waiting for Mark Williams to release an ANSI C compiler for the ST!!! Surprisingly, Mark Williams C 2.0 already has a lot of ANSI C in it. But the naughties, they #define __STDC__ but do *not* implement all of ANSI C, so that programs that I have that compile differently depending on the absence or presence of __STDC__ don't work. It would have been better not to have defined __STDC__ until everything was implemented. I don't know about MWC version 3, because it has taken me nearly a year to get it, and it *still* hasn't arrived. Why is the Dutch distribution of MWC so bad? The Dutch distributors that I was using (Compudress) blame Mark Williams, but I've had such bad experiences with them on other matters, that it's difficult to tell whether they're telling the truth. Steven Pemberton, CWI, Amsterdam; steven@cwi.nl "Let us go then you and I/while the night is laid out against the sky/like a smear of mustard on an old pork pie" "Nice poem Tom. I have suggestions for changes though, why not come over?"- Ez. The above are my opinions and do not reflect CWI's opinions and policies.
saj@chinet.chi.il.us (Stephen Jacobs) (05/18/89)
There have been some musings about when/whether Mark Williams Co is going to do an ANSI C compiler. I've had several occasions in recent months to ask people at Mark Williams about upcoming improvements in documentation and compiler performance. They've been very open about rather large amounts of future probabilities. As of six months ago, more than one knowledgeable MW employee expected their ANSI-compliant compiler to be in beta test by now. More recently, they have been optimistic, but a little more restrained. Nobody ever outright promised ANYTHING except that it was being worked on. They are a strange company to deal with: very helpful and friendly, but often rather disorganized. I guess they don't want to get a reputation for vapor, so the first >official< mention of their ANSI compiler will probably be when they offer it for sale. Steve J.
dag@per2.UUCP (Daniel A. Glasser) (05/19/89)
In article <8120@boring.cwi.nl>, steven@cwi.nl (Steven Pemberton) writes: > > Surprisingly, Mark Williams C 2.0 already has a lot of ANSI C in it. > But the naughties, they #define __STDC__ but do *not* implement all of > ANSI C, so that programs that I have that compile differently > depending on the absence or presence of __STDC__ don't work. It would > have been better not to have defined __STDC__ until everything was > implemented. > __STDC__ is defined as 0 in MWC V3.0 (and earlier). This means that the compiler is NOT compliant with ANSI C in these releases. The preprocessor, however, is compliant in V3.0 and I believe 2.0 as well. The simple presence of the __STDC__ definition is not sufficient to tell if you are using an ANSI compiler, you must check the value of the macro. Ie, don't use "#ifdef __STDC__", use instead "#if __STDC__". If the macro is undefined, the #if evaluates to false. If your preprocessor does not allow #if on undefined symbols, it isn't even Unix V7 compatible. Section 3.8.8 of the ANSI X3J11 standard defines __STDC__ to be the decimal constant 1. It is not the compiler that has it wrong... Daniel A. Glasser -- _____________________________________________________________________________ Daniel A. Glasser One of those things that goes uwvax!per2!dag "BUMP!!!(ouch)" in the night. ---Persoft, Inc.---------465 Science Drive-------Madison, WI 53711-----------
siebren@cwi.nl (Siebren van der Zee) (05/23/89)
In article <857@per2.UUCP> dag@per2.UUCP (Daniel A. Glasser) writes: >In article <8120@boring.cwi.nl>, steven@cwi.nl (Steven Pemberton) writes: >> Surprisingly, Mark Williams C 2.0 already has a lot of ANSI C in it. >> But the naughties, they #define __STDC__ but do *not* implement all of >__STDC__ is defined as 0 in MWC V3.0 (and earlier). This means that the [...] >Ie, don't use "#ifdef __STDC__", use instead "#if __STDC__". If the >macro is undefined, the #if evaluates to false. If your preprocessor >does not allow #if on undefined symbols, it isn't even Unix V7 compatible. >Section 3.8.8 of the ANSI X3J11 standard defines __STDC__ to be the >decimal constant 1. (Steven is a collegue of mine, I complained about this on the net too) So what? They put in an annoying symbol that has _NO_ meaning, and _NO_ purpose other that polluting my namespace. Remember that once, a long, long time ago, #if did not even exist. Not even for defined symbols. Steven's config program works for all compilers I know of, including one that doesn't implement #if. Ever thought about how careful you have to code to accomplish that? Ok, then MWC comes around, defines a macro without any meaning, but completely correct. He had to make a decision whether to support MWC or the other compiler. I think his decision not to support MWC V3 is the right one, especially since they are probably working on an ANSI version. > >It is not the compiler that has it wrong... That right. But that doesn't solve our problems. If only somebody could explain to me what use the definition of __STDC__ as 0 might mean, why I might want to have my compiler to define it... Siebren van der Zee, siebren@cwi.nl -- waiting for MWC V4
saj@chinet.chi.il.us (Stephen Jacobs) (05/24/89)
In article <8137@boring.cwi.nl>, siebren@cwi.nl (Siebren van der Zee) writes: > In article <857@per2.UUCP> dag@per2.UUCP (Daniel A. Glasser) writes: > >In article <8120@boring.cwi.nl>, steven@cwi.nl (Steven Pemberton) writes: > >> Surprisingly, Mark Williams C 2.0 already has a lot of ANSI C in it. > >> But the naughties, they #define __STDC__ but do *not* implement all of > If only somebody could explain to me what use the definition of __STDC__ > as 0 might mean, why I might want to have my compiler to define it... > > Siebren van der Zee, siebren@cwi.nl -- waiting for MWC V4 This whole discussion has been about telling whether a compiler complies with the proposed standard. Defining __STDC__ as zero is a very reasonable way of telling a program that you don't comply with the standard. As far as I can see, it's the only way that's consistent with the obviously intended 'Other Shoe': a future language standard will define __STDC__ as 2. As to why one might want a non-complying compiler in a world of complying ones, there are the usual maintenance/library arguments. I've seen machines with 3 generations of FORTRAN compilers, or 2 levels of Pascal available. Steve J.