File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 1212 }
1313}
1414
15- %lex-param { MC_Scanner &scanner }
1615%parse-param { MC_Scanner &scanner }
17-
18- %lex-param { MC_Driver &driver }
1916%parse-param { MC_Driver &driver }
2017
2118%code {
2522
2623 /* include for all driver functions */
2724 #include " mc_driver.hpp"
28-
29- /* this is silly, but I can't figure out a way around */
30- static int yylex (MC::MC_Parser::semantic_type *yylval,
31- MC::MC_Scanner &scanner,
32- MC::MC_Driver &driver);
33-
25+
26+ #undef yylex
27+ #define yylex scanner.yylex
3428}
3529
3630/* token types */
@@ -75,15 +69,3 @@ MC::MC_Parser::error( const std::string &err_message )
7569{
7670 std::cerr << " Error: " << err_message << " \n " ;
7771}
78-
79-
80- /* include for access to scanner.yylex */
81- #include " mc_scanner.hpp"
82- static int
83- yylex ( MC::MC_Parser::semantic_type *yylval,
84- MC::MC_Scanner &scanner,
85- MC::MC_Driver &driver )
86- {
87- return ( scanner.yylex (yylval) );
88- }
89-
You can’t perform that action at this time.
0 commit comments