You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
[Bug] Bison file prefixes for C/C++ not generating correctly #172
When generating C or C++ and using prefixes, the generated Bison-file is missing the prefixes in the error function. Example (take any well-formed and otherwise working Test.cf):
bnfc -m --cpp -p test Test.cf
the generated Test.y will have missing prefixes in the error function:
void testyyerror(const char *str)
{
extern char *testyytext;
fprintf(stderr,"error: line %d: %s at %s\n",
yy_mylinenumber, str, yytext);
}
but it should prepend the prefixes on all the variable references in that function:
void testyyerror(const char *str)
{
extern char *testyytext;
fprintf(stderr,"error: line %d: %s at %s\n",
testyy_mylinenumber, str, testyytext);
}
I believe that @pascalh's pull request #174 is solving this issue. @dcavar if you have time to test it and there is still a problem, feel free to re-open it.
Activity
pascalh commentedon Mar 8, 2016
I applied the suggested changes to the C++-backend in my branch. Please confirm that my changes solve the issue.
dcavar commentedon Mar 8, 2016
Dear Pascal,
As far as I can tell, the Bison-issue is not solved. The previous issues with multi-character comment delimiters seem to be solved, though.
DC
On 03/08/2016 08:20 AM, Pascal Hof wrote:
Damir Cavar
https://linguistlist.org/people/damir_cavar.html
[-]Prefixes not generating correctly .y files [/-][+][Bug] Bison file prefixes for C/C++ not generating correctly[/+]gdetrez commentedon Aug 23, 2016
I believe that @pascalh's pull request #174 is solving this issue. @dcavar if you have time to test it and there is still a problem, feel free to re-open it.