C++ and YACC (?)

Griff Smith ggs at ulysses.UUCP
Tue Feb 4 00:38:57 AEST 1986


> Will YACC and C++ inter-operate properly?
> Or would a new sort of "language hosting" need to be done for C++?
> Has anybody done a parser using YACC and C++?
> 
> I won't
> have to call yyparse() lots of times (I couldn't figure that one
> out when I tried a couple of years ago).  But I will need to be
> using some code that's C to call code that's C++.  Or maybe I can
> just compile the yacc output with C++ instead of C?
> 
> Any suggestions?
> -- 
> David Herron,  cbosgd!ukma!david, david at UKMA.BITNET, soon, david at uky.csnet.
> 
The output of YACC is compatible with C++.  The compiler grumbles a bit
about the sloppy function declarations, but there are no fatal errors.
Lex is a bit worse; the complaints from the compiler are a bit louder,
though still non-fatal.  I run the output of lex through a sed script
to clean up warnings plus a few self-inflicted problems.
-- 

Griff Smith	AT&T (Bell Laboratories), Murray Hill
Phone:		(201) 582-7736
Internet:	ggs at ulysses.uucp
UUCP:		ulysses!ggs  ( {allegra|ihnp4}!ulysses!ggs )



More information about the Comp.lang.c mailing list