[comp.archives] [c++] Re: Multiple parsers in C++?

lma@dayton.Stanford.EDU (Larry Augustin) (03/29/91)

Archive-name: languages/parsers/bison++/1991-03-27
Archive: wilbur.stanford.edu:/pub/bison++-1.02.tar.Z [36.14.0.30]
Original-posting-by: lma@dayton.Stanford.EDU (Larry Augustin)
Original-subject: Re: Multiple parsers in C++?
Reposted-by: emv@msen.com (Edward Vielmetti, MSEN)

sdm@cs.brown.edu (Scott Meyers) writes:

>I'm writing an application that needs to use multiple lexers and parsers.
>The ideal situation would be to use modified versions of lex and yacc so
>that each lexer/parser was in its own class.  This is sort of done by
>bison++, but it currently generates code that won't compile under anything
>but g++ (it initializes data members inside the class declaration).

Scott and I have exchanged some email on this subject, and I'm willing
to modify bison++ to work with other C++ compilers.  But I'm certainly
not a C++ guru, and I'd like to hear suggestions as to the best way to
generate the class headers.  (See my previous posting on the subject.)

So please send me suggestions for the best way to structure the
bison++ parser class.  I'll make the changes to bison++ and announce
the new version when it's available.

As for flex++, I personally just write scanners by hand.  But I'll
look at it.

As always, bison++ is available for anonymous ftp from
wilbur.stanford.edu.

Larry M. Augustin			ERL 414
lma@sierra.stanford.edu			Computer Systems Lab
lma@dayton.stanford.edu			Stanford University
(415) 723-9285				Stanford, CA 94305
-- 
Larry M. Augustin			   _         _      _     ____
					  | |	    | \    / |	 / __ \
ARPA: lma@sierra.stanford.edu		  | |	    |  \__/  |	| (__) |
BITNET: lma%sierra.stanford.edu@stanford  | |	    | |\  /| |	|  __  |
UUCP:...!ucbvax!sierra.stanford.edu!lma   | |____   | | \/ | |	| |  | |
AT&T: (415) 324-4929			  |______|  |_|    |_|	|_|  |_|