after upgrading from bison 2.7 to 3.0 I changed the following two lines in my parser definition file (.yy)
-------old--------
%define parser_class_name smathparser
%name-prefix = "imath"
-------new--------
%define api.prefix {imath}
%define parser_class_name {smathparser}
-------------------
and the result is that I get the following compiler errors when compiling the parser (!) file (compiling the lexer file gives no errors even though it uses yylval heavily):
error: ‘yylval’ was not declared in this scope
error: ‘yylloc’ was not declared in this scope
I searched everywhere I could think of but I couldn't see where yylval and yylloc are being defined. Have they been renamed? Deprecated? Why do they work in the lexer but not in the parser????
For clarification: I am actually using yylval and yylloc in the code of the parser.