aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/LuaSL/src
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--LuaSL/src/LuaSL_yaccer.y13
1 files changed, 5 insertions, 8 deletions
diff --git a/LuaSL/src/LuaSL_yaccer.y b/LuaSL/src/LuaSL_yaccer.y
index 9b060b5..4b456b1 100644
--- a/LuaSL/src/LuaSL_yaccer.y
+++ b/LuaSL/src/LuaSL_yaccer.y
@@ -50,14 +50,13 @@
50%% 50%%
51 51
52input : 52input :
53 ignorable { } 53 ignorable
54 | expr { ((LuaSL_yyparseParam*)data)->ast = addOperation(LSL_EXPRESSION, $1, $1); } 54 | expr { ((LuaSL_yyparseParam*)data)->ast = addOperation(LSL_EXPRESSION, $1, $1); }
55 | statement { ((LuaSL_yyparseParam*)data)->ast = addStatement($1, ((LuaSL_yyparseParam*)data)->ast); } 55 | statement { ((LuaSL_yyparseParam*)data)->ast = addStatement($1, ((LuaSL_yyparseParam*)data)->ast); }
56 | script { } 56 | script
57; 57;
58 58
59ignorable : 59ignorable : LSL_SPACE { ((LuaSL_yyparseParam*)data)->ast = addSpace($1, ((LuaSL_yyparseParam*)data)->ast); }
60 LSL_SPACE { ((LuaSL_yyparseParam*)data)->ast = addSpace($1, ((LuaSL_yyparseParam*)data)->ast); }
61; 60;
62 61
63expr : 62expr :
@@ -86,12 +85,10 @@ expr :
86 | LSL_INTEGER { $$ = addInteger($1); } 85 | LSL_INTEGER { $$ = addInteger($1); }
87; 86;
88 87
89statement : 88statement : expr LSL_STATEMENT { $$ = createStatement(LSL_EXPRESSION, $1); YYVALID; }
90 expr LSL_STATEMENT { $$ = createStatement(LSL_EXPRESSION, $1); YYVALID; }
91; 89;
92 90
93script : 91script : script LSL_STATEMENT statement
94 script LSL_STATEMENT statement
95 92
96%% 93%%
97 94