aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/LuaSL/src
diff options
context:
space:
mode:
authorDavid Walter Seikel2012-02-02 13:27:49 +1000
committerDavid Walter Seikel2012-02-02 13:27:49 +1000
commit15170d779b5b6782407d4980ac4660bb612540fb (patch)
tree32c1cb913445ee70c98ac3b005d268be822a4179 /LuaSL/src
parentWhite space prettiness. (diff)
downloadSledjHamr-15170d779b5b6782407d4980ac4660bb612540fb.zip
SledjHamr-15170d779b5b6782407d4980ac4660bb612540fb.tar.gz
SledjHamr-15170d779b5b6782407d4980ac4660bb612540fb.tar.bz2
SledjHamr-15170d779b5b6782407d4980ac4660bb612540fb.tar.xz
Zaro boogs! B-)
Diffstat (limited to 'LuaSL/src')
-rw-r--r--LuaSL/src/LuaSL_compile.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/LuaSL/src/LuaSL_compile.c b/LuaSL/src/LuaSL_compile.c
index cf9d767..d32a44f 100644
--- a/LuaSL/src/LuaSL_compile.c
+++ b/LuaSL/src/LuaSL_compile.c
@@ -1001,19 +1001,20 @@ LSL_Leaf *addStatement(LuaSL_compiler *compiler, LSL_Leaf *lval, LSL_Leaf *flow,
1001 1001
1002LSL_Leaf *collectStatements(LuaSL_compiler *compiler, LSL_Leaf *list, LSL_Leaf *statement) 1002LSL_Leaf *collectStatements(LuaSL_compiler *compiler, LSL_Leaf *list, LSL_Leaf *statement)
1003{ 1003{
1004 boolean wasNull = FALSE; 1004// Guess this is not needed after all, and seemed to cause the "states with only one function get dropped" bug.
1005// boolean wasNull = FALSE;
1005 1006
1006 if (NULL == list) 1007 if (NULL == list)
1007 { 1008 {
1008 list = newLeaf(LSL_BLOCK_OPEN, NULL, NULL); 1009 list = newLeaf(LSL_BLOCK_OPEN, NULL, NULL);
1009 wasNull = TRUE; 1010// wasNull = TRUE;
1010 } 1011 }
1011 1012
1012 if (list) 1013 if (list)
1013 { 1014 {
1014 if (statement) 1015 if (statement)
1015 { 1016 {
1016 if (!wasNull) 1017// if (!wasNull)
1017 list->value.blockValue = compiler->currentBlock; // Maybe NULL. 1018 list->value.blockValue = compiler->currentBlock; // Maybe NULL.
1018 1019
1019 if ((compiler->inState) && (LSL_FUNCTION == statement->value.statementValue->type)) 1020 if ((compiler->inState) && (LSL_FUNCTION == statement->value.statementValue->type))