edited symbol table functions
This commit is contained in:
22
grammar.y
22
grammar.y
@ -54,12 +54,20 @@
|
||||
%token RELEASE 614
|
||||
%token COMMENT 700
|
||||
%%
|
||||
B : '{'{CreateScope(cur,line,column)} E '}'; //Braced Expressions can have braces removed to get regular expressions
|
||||
D : '[' l ']'; //Declaration Lists Brackets can be taken out to get a list of Declarations
|
||||
E : Maybe_D U; //An expression can start with an optional D followed by an undeclared segment
|
||||
Maybe_D : D
|
||||
| ; //Either D or not
|
||||
l : A ';' l;
|
||||
| ; //a declaration list can either be empty or be an assignment followed by a semi-colon and another list
|
||||
|
||||
start: /*empty for now*/
|
||||
;
|
||||
// B : '{'{CreateScope(cur,line,column)} E '}'; //Braced Expressions can have braces removed to get regular expressions
|
||||
// D : '[' l ']'; //Declaration Lists Brackets can be taken out to get a list of Declarations
|
||||
// E : Maybe_D U; //An expression can start with an optional D followed by an undeclared segment
|
||||
// Maybe_D : D
|
||||
// | ; //Either D or not
|
||||
//l : A ';' l;
|
||||
// | ; //a declaration list can either be empty or be an assignment followed by a semi-colon and another list
|
||||
|
||||
%%
|
||||
|
||||
int main() {
|
||||
return yyparse();
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user