aboutsummaryrefslogtreecommitdiff
path: root/lib/forlangrm.y
diff options
context:
space:
mode:
authorSergey Poznyakoff <gray@gnu.org.ua>2012-10-02 21:28:19 +0300
committerSergey Poznyakoff <gray@gnu.org.ua>2012-10-02 21:28:19 +0300
commit933cf5581f0b3fa11098d36bfeedda9f2bae521f (patch)
treeeae15d34efb9f83c8649c73f16782d66d59275c3 /lib/forlangrm.y
parent1c6564dc95e91b5a07a528cf192bdd1f5133225b (diff)
downloadeclat-933cf5581f0b3fa11098d36bfeedda9f2bae521f.tar.gz
eclat-933cf5581f0b3fa11098d36bfeedda9f2bae521f.tar.bz2
Improve grammar.
Diffstat (limited to 'lib/forlangrm.y')
-rw-r--r--lib/forlangrm.y27
1 files changed, 10 insertions, 17 deletions
diff --git a/lib/forlangrm.y b/lib/forlangrm.y
index 884ff1e..eb7fc6f 100644
--- a/lib/forlangrm.y
+++ b/lib/forlangrm.y
@@ -171,23 +171,6 @@ node : rval
{
$$ = forlan_node_create(forlan_type_comp);
}
- | LAST
- {
- $$ = forlan_node_create(forlan_type_last);
- }
- | IDENT
- {
- $$ = forlan_node_create(forlan_type_var);
- $$->var.idx = find_variable($1);
-// free($1);
- }
- | IDENT '.' complist
- {
- union forlan_node *node =
- forlan_node_create(forlan_type_var);
- node->var.idx = find_variable($1);
- $$ = create_comp_node(node, $3.list, $3.wildcards);
- }
;
complist : comp
@@ -290,11 +273,21 @@ funcall : IDENT '(' ')'
;
rval : funcall
+ | LAST
+ {
+ $$ = forlan_node_create(forlan_type_last);
+ }
| STRING
{
$$ = forlan_node_create(forlan_type_lit);
$$->lit.string = $1;
}
+ | IDENT
+ {
+ $$ = forlan_node_create(forlan_type_var);
+ $$->var.idx = find_variable($1);
+// free($1);
+ }
;
arglist : arg

Return to:

Send suggestions and report system problems to the System administrator.