style: rename user_token_number as code

This should have been done in 3.6, but I wanted to avoid introducing
conflicts into Vincent's work on counterexamples.  It turns out it's
completely orthogonal.

* data/README.md, data/skeletons/bison.m4, data/skeletons/c++.m4,
* data/skeletons/c.m4, data/skeletons/glr.c, data/skeletons/java.m4,
* data/skeletons/lalr1.d, data/skeletons/lalr1.java,
* data/skeletons/variant.hh, data/skeletons/yacc.c, src/conflicts.c,
* src/derives.c, src/gram.c, src/gram.h, src/output.c,
* src/parse-gram.c, src/parse-gram.y, src/print-xml.c, src/print.c,
* src/reader.c, src/symtab.c, src/symtab.h, tests/input.at,
* tests/types.at:
s/user_token_number/code/g.
Plus minor changes.
This commit is contained in:
Akim Demaille
2020-05-22 20:12:03 +02:00
parent 339d11badf
commit e7aff57122
25 changed files with 88 additions and 95 deletions

View File

@@ -95,11 +95,11 @@ The macro `b4_symbol(NUM, FIELD)` gives access to the following FIELDS:
- `tag`: string
A human representation of the symbol. Can be 'foo', 'foo.id', '"foo"' etc.
- `user_number`: integer
The code associated to the `id`.
- `code`: integer
The token code associated to the `id`.
The external number as used by yylex. Can be ASCII code when a character,
some number chosen by bison, or some user number in the case of
%token FOO <NUM>. Corresponds to yychar in yacc.c.
some number chosen by bison, or some user number in the case of `%token
FOO <NUM>`. Corresponds to `yychar` in `yacc.c`.
- `is_token`: 0 or 1
Whether this is a terminal symbol.