nmodl icon indicating copy to clipboard operation
nmodl copied to clipboard

Replace deprecated bison commands

Open JCGoran opened this issue 11 months ago • 6 comments

TODO:

  • [ ] according to the docs, updating name-prefix to api.prefix is a bit non-trivial, and a naive fix results in compilation errors. For reference, here's the relevant section:
    The '%name-prefix "xx"' directive is deprecated in favor of '%define
    api.prefix {xx}' since Bison 3.0, but no warning was issued.  These
    directives are slightly different, you might need to adjust your code.
    %name-prefix renames only symbols with external linkage, while api.prefix
    also renames types and macros, including YYDEBUG, YYTOKENTYPE,
    yytokentype, YYSTYPE, YYLTYPE, etc.
    
    Users of Flex that move from '%name-prefix "xx"' to '%define api.prefix
    {xx}' will typically have to update YY_DECL from
    
    #define YY_DECL int xxlex (YYSTYPE *yylval, YYLTYPE *yylloc)
    
    to
    
    #define YY_DECL int xxlex (XXSTYPE *yylval, XXLTYPE *yylloc)
    

JCGoran avatar Mar 18 '24 09:03 JCGoran