help-bison
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: multiple grammars/parser with common parts


From: Jeremy Elson
Subject: Re: multiple grammars/parser with common parts
Date: Thu, 11 Mar 2004 12:05:59 -0800

Thomas Lavergne writes:
>I have a question  more on the conception point of vie of complex 
>packages using  bison/flex:
[...]
>In my parser file (bison.y), I am allowed to use #include, #ifdef, 
>etc... so I think I can manage this by compiling twice my bison.y but 
>with different prefix (-p prefix) and some #ifdef EXE1 and #ifdef EXE2 
>blocks. Anyway, I would like to know if there is any other solution 
>(providing that this one works: not tested)?

I am trying to solve the same problem.  #include and #ifdef do not
work in the part of the bison input where rules are defined.  Right
now I am, sadly, using cut and paste to keep my two similar grammars
in sync.  If you find a better solution I'd like to know :-)

Jer




reply via email to

[Prev in Thread] Current Thread [Next in Thread]