aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/LuaSL
diff options
context:
space:
mode:
authorDavid Walter Seikel2012-01-14 08:45:48 +1000
committerDavid Walter Seikel2012-01-14 08:45:48 +1000
commitf8e387dde17e1e64ae83b9162d5042a80e0c82aa (patch)
tree497386849a3872b2505b91b9d7e567ff53e19083 /LuaSL
parentGeneric type handling, and add the float type. (diff)
downloadSledjHamr-f8e387dde17e1e64ae83b9162d5042a80e0c82aa.zip
SledjHamr-f8e387dde17e1e64ae83b9162d5042a80e0c82aa.tar.gz
SledjHamr-f8e387dde17e1e64ae83b9162d5042a80e0c82aa.tar.bz2
SledjHamr-f8e387dde17e1e64ae83b9162d5042a80e0c82aa.tar.xz
Little bit of clean up.
Diffstat (limited to 'LuaSL')
-rw-r--r--LuaSL/src/LuaSL_LSL_tree.c2
-rw-r--r--LuaSL/src/LuaSL_LSL_tree.h6
-rw-r--r--LuaSL/src/LuaSL_lexer.l1
3 files changed, 5 insertions, 4 deletions
diff --git a/LuaSL/src/LuaSL_LSL_tree.c b/LuaSL/src/LuaSL_LSL_tree.c
index 5c97719..98a03e7 100644
--- a/LuaSL/src/LuaSL_LSL_tree.c
+++ b/LuaSL/src/LuaSL_LSL_tree.c
@@ -22,7 +22,7 @@ LSL_Token LSL_Tokens[] =
22 {LSL_SPACE, ST_NONE, " ", LSL_NONE, NULL, NULL, NULL}, 22 {LSL_SPACE, ST_NONE, " ", LSL_NONE, NULL, NULL, NULL},
23 23
24 // Operators, in order of precedence, low to high 24 // Operators, in order of precedence, low to high
25 // Left to right, unless oterwise stated. 25 // Left to right, unless otherwise stated.
26 // According to http://wiki.secondlife.com/wiki/Category:LSL_Operators 26 // According to http://wiki.secondlife.com/wiki/Category:LSL_Operators
27 {LSL_BOOL_AND, ST_BOOLEAN, "&&", LSL_RIGHT2LEFT, NULL, NULL, evaluateOperationToken}, 27 {LSL_BOOL_AND, ST_BOOLEAN, "&&", LSL_RIGHT2LEFT, NULL, NULL, evaluateOperationToken},
28// QUIRK - Seems to be some disagreement about BOOL_AND/BOOL_OR precedence. Either they are equal, or OR is higher. 28// QUIRK - Seems to be some disagreement about BOOL_AND/BOOL_OR precedence. Either they are equal, or OR is higher.
diff --git a/LuaSL/src/LuaSL_LSL_tree.h b/LuaSL/src/LuaSL_LSL_tree.h
index d2d767c..2ef48ee 100644
--- a/LuaSL/src/LuaSL_LSL_tree.h
+++ b/LuaSL/src/LuaSL_LSL_tree.h
@@ -231,13 +231,15 @@ struct _LSL_Identifier // For variables and function parameters.
231 231
232struct _LSL_Statement 232struct _LSL_Statement
233{ 233{
234 LSL_Leaf *expressions; /// For things like a for statement, might hold three expressions. 234 LSL_Leaf *expressions; // For things like a for statement, might hold three expressions.
235 LSL_Type type; // Expression type. 235 LSL_Type type; // Expression type.
236}; 236};
237 237
238struct _LSL_Block 238struct _LSL_Block
239{ 239{
240 LSL_Block *outerBlock;
240 LSL_Statement *statements; 241 LSL_Statement *statements;
242 LSL_Identifier *scopeVariables;
241}; 243};
242 244
243struct _LSL_Function 245struct _LSL_Function
diff --git a/LuaSL/src/LuaSL_lexer.l b/LuaSL/src/LuaSL_lexer.l
index 2b57f68..05134bc 100644
--- a/LuaSL/src/LuaSL_lexer.l
+++ b/LuaSL/src/LuaSL_lexer.l
@@ -2,7 +2,6 @@
2 2
3#define excludeLexer 3#define excludeLexer
4#include "LuaSL_LSL_tree.h" 4#include "LuaSL_LSL_tree.h"
5#include <stdio.h>
6 5
7int common(YYSTYPE *lval, char *text, LuaSL_yyparseExtra *extra, boolean checkIgnorable, int type); 6int common(YYSTYPE *lval, char *text, LuaSL_yyparseExtra *extra, boolean checkIgnorable, int type);
8 7