Re: Lookahead vs. Scanner Feedback

burley@geech.gnu.ai.mit.edu (Craig Burley)
7 Jan 92 19:22:18 GMT

          From comp.compilers

Related articles
Lookahead vs. Scanner Feedback hjelm+@cs.cmu.edu (1992-01-03)
Re: Lookahead vs. Scanner Feedback rockwell@socrates.umd.edu (Raul Deluth Miller-Rockwell) (1992-01-04)
Re: Lookahead vs. Scanner Feedback bliss@sp64.csrd.uiuc.edu (1992-01-07)
Re: Lookahead vs. Scanner Feedback sef@kithrup.COM (1992-01-07)
Re: Lookahead vs. Scanner Feedback Jan.Rekers@cwi.nl (1992-01-07)
Re: Lookahead vs. Scanner Feedback burley@geech.gnu.ai.mit.edu (1992-01-07)
Re: Lookahead vs. Scanner Feedback drw@lagrange.mit.edu (1992-01-07)
Re: Lookahead vs. Scanner Feedback smk@dcs.edinburgh.ac.uk (1992-01-07)
Re: Lookahead vs. Scanner Feedback bill@twwells.com (1992-01-08)
Re: Lookahead vs. Scanner Feedback bliss@sp64.csrd.uiuc.edu (1992-01-08)
Re: Lookahead vs. Scanner Feedback nigelh@sol.UVic.CA (1992-01-08)
Re: Lookahead vs. Scanner Feedback dww@inf.fu-berlin.de (1992-01-08)
[4 later articles]
| List of all articles for this month |

Newsgroups: comp.compilers
From: burley@geech.gnu.ai.mit.edu (Craig Burley)
Keywords: parse, yacc, C, GCC
Organization: Free Software Foundation 545 Tech Square Cambridge, MA 02139
References: 92-01-012 92-01-022
Date: 7 Jan 92 19:22:18 GMT

In article 92-01-022 bliss@sp64.csrd.uiuc.edu (Brian Bliss) writes:


      One place where every yacc/lex based C compiler I know of is
      broken is on a typedef name redefined in an inner scope:


      typedef int foo;


      main ()
            {
char foo;
            }


      is legal ANSI C. I think there was a thread on this a while back.


Well, take GNU C (versions 1.something and 2) off your list of broken
yacc/lex-based compilers. (Ok, it's not lex-based and it is bison-based,
but I don't think that matters.) I just tried this example on both
versions and it works fine.
--
James Craig Burley, Software Craftsperson burley@gnu.ai.mit.edu
--


Post a followup to this message

Return to the comp.compilers page.
Search the comp.compilers archives again.