Open
Description
A #define directive in the .tab.cpp file will replace yyerror with - for example - YBerror. However, a token named YBerror has been introduced already in the .tab.hpp file in the enumeration YBtokentype with the value 255. Under Linux this token will not be generated. Hence, there is no conflict in the Linux case. If no API prefix is used, the token features the name "YYerror". The #define will not be present and there is no conflict with the yyerror function thanks to case sensitivity.
There is a workaround which consists in undefining yyerror at the proper moment. In certain applications this will work. In other cases linker issues will arise as each parser creates the same yyerror symbol. The attached example illustrates the problem.
Metadata
Metadata
Assignees
Labels
No labels