X-Git-Url: https://git.saurik.com/bison.git/blobdiff_plain/cdf3f113388c74730337663f7f367f49ffebe12c..b987342bab23bb8c12b15cfbbda73aa6ff09f238:/NEWS diff --git a/NEWS b/NEWS index bbf25383..76d8f4b2 100644 --- a/NEWS +++ b/NEWS @@ -9,6 +9,22 @@ Bison News Also, it is possible to add code to the parser's constructors using "%code init" and "%define init_throws". +** Variable api.tokens.prefix + + The variable api.tokens.prefix changes the way tokens are identified in + the generated files. This is especially useful to avoid collisions + with identifiers in the target language. For instance + + %token FILE for ERROR + %define api.tokens.prefix "TOK_" + %% + start: FILE for ERROR; + + will generate the definition of the symbols TOK_FILE, TOK_for, and + TOK_ERROR in the generated sources. In particular, the scanner must + use these prefixed token names, although the grammar itself still + uses the short names (as in the sample rule given above). + * Changes in version 2.5 (????-??-??): ** IELR(1) and Canonical LR(1) Support