diff options
Diffstat (limited to 'src/parser.y')
-rw-r--r-- | src/parser.y | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/src/parser.y b/src/parser.y index 9f532b9..dd177d0 100644 --- a/src/parser.y +++ b/src/parser.y @@ -53,6 +53,7 @@ %token PLUS "+" %token XOR "^" %token AND "&" +%token BAR "|" %token TILDE "~" %token LT "<" %token GT ">" @@ -183,6 +184,7 @@ var rev_vars : rev_vars "," var { $$ = $3; $$->n = $1; } + | rev_vars "|" var { $$ = $3; $$->n = $1; opt_group($1, $3); } | var vars @@ -230,7 +232,7 @@ type | "*" type { $$ = tgen_ptr($2, src_loc(@$)); } rev_types - : rev_types "," type { $$ = $3; $3->n = $$; } + : rev_types "," type { $$ = $3; $$->n = $1; } | type types |