added config files
This commit is contained in:
parent
e0b407f8fb
commit
fd2d08fb24
7 changed files with 90 additions and 54 deletions
30
README.md
Normal file
30
README.md
Normal file
|
|
@ -0,0 +1,30 @@
|
|||
# Parser
|
||||
## Explanation of options:
|
||||
```cpp
|
||||
// Bison version
|
||||
%require "3.0.4"
|
||||
|
||||
// skeleton program to be used as parser
|
||||
%skeleton "lalr1.cc"
|
||||
|
||||
// tells bison to generate a header file
|
||||
%defines
|
||||
|
||||
// where the parser will live (in what namespace)
|
||||
%define api.prefix {yy}
|
||||
|
||||
// the name of parser class
|
||||
%define api.parser.class {Parser}
|
||||
|
||||
/* it will generate a location class which can be used in your lexer */
|
||||
%locations
|
||||
|
||||
/* use the constructor for each token, and make_TOKENNAME functions will be generated */
|
||||
%define api.token.constructor
|
||||
|
||||
/* use the variant type for $1~$n and $$ those variables */
|
||||
%define api.value.type variant
|
||||
|
||||
%define parse.trace
|
||||
%define parse.error verbose
|
||||
```
|
||||
Loading…
Add table
Add a link
Reference in a new issue