home *** CD-ROM | disk | FTP | other *** search
- Newsgroups: comp.sys.sgi
- Path: sparky!uunet!ukma!darwin.sura.net!sgiblab!sgigate!sgi!quasar.mti.sgi.com!davea
- From: davea@quasar.mti.sgi.com (David B.Anderson)
- Subject: Re: Bug in SGI ansi compliance (or are the others wrong ?)
- Message-ID: <s9gbbos@sgi.sgi.com>
- Sender: davea@quasar.mti.sgi.com
- Organization: Silicon Graphics, Inc. Mountain View, CA
- Date: Thu, 12 Nov 1992 20:19:32 GMT
- Lines: 38
-
- In article <1992Nov11.225422.2888@bernina.ethz.ch> hoesel@igc.ethz.ch (Frans van Hoesel) writes:
- >In article <s5c02sg@sgi.sgi.com> davea@quasar.mti.sgi.com (David B.Anderson) writes:
- >>In article <1992Nov9.140450.591@bernina.ethz.ch> torda@igc.ethz.ch (Andrew Torda) writes:
- >>>The following two lines of code don't compile with the -ansi option to
- >>>the sgi cc compiler (version 3.10)
- >>>
- >>>---------- begin code ----------
- >>>#include <stdio.h>
- >>>FILE *fp = stdout;
- >>>---------- end code ----------
- >>>
- >>>% cc -c -ansi z.c
- >>>accom: Error: z.c, line 2: integer constant expected
- >>> FILE *fp = (__stdout) ;
- >>> ----------------------------^
- >>
- >>This (normally minor)annoyance was introduced with -ansi because
- >[removed]
-
- >You might find it a '(normally minor)annoyance' but lex produces code
- >that does *NOT* compile using -ansi, exactly because of the above reason!!
- >(you can check that easely by creating a file with two lines of '%%'
- >(a minimal lex program) run lex with it, and try to compile with -ansi)
-
- The problem with lex had been reported already... I was wrong to call the
- problem 'minor' since it would break -ansi compilations of lex output
- files. At the time we made the decison to create __stdout we were not aware
- of the unfortunate interaction with lex.
-
- Anyone using -xansi would not have the problem.
-
- In the next major release the problem has been fixed 'properly'.
-
- Sorry about the inconvenience.
- [ David B. Anderson (415)390-4263 davea@sgi.com ]
-
-
-
-