|
From: | Bob Smith |
Subject: | Re: Name Conflict With Multiple Parsers In Same Program |
Date: | Wed, 13 Jun 2007 17:38:14 -0500 |
User-agent: | Thunderbird 2.0.0.0 (Windows/20070326) |
On 6/13/2007 5:16 PM, Hans Aberg wrote:
On 13 Jun 2007, at 19:09, Paul Eggert wrote:Do I understand you correctly in saying that you're trying to do a single C compilation that #includes two different Bison-generated .c files?Oops, I missed that on Help-Bison. :-)That would explain the problem: Bison doesn't support that, and is designed only for separate compilation.On the other hand, if there are only four names which haven't been namespacified, would it be difficult to admit it?
The compilations are separate: one in file <parse.c> and the other in file <dfnhdr.c> each generated by Bison from the respective .y files.
The #includes common to all files are the .pro files generated by the C compiler. Each .pro file contains the prototypes for each function in the corresponding .c file.
The problem I have is that the .pro files corresponding to the two parser-generated .c files each contain a prototype for the four functions I mentioned before. However, because of the different use of %lex-param in the two parser files, the prototype for (say) yydestruct is different in the two .pro files.
If you like, I'd be glad to generate a minimal set of files which reproduces the problem.
-- _______________________________________________________________ Bob Smith - address@hidden - http://www.sudleyplace.com
[Prev in Thread] | Current Thread | [Next in Thread] |