diff options
author | David Walter Seikel | 2012-01-23 19:53:05 +1000 |
---|---|---|
committer | David Walter Seikel | 2012-01-23 19:53:05 +1000 |
commit | 5d79985fe7d3873f9d4a82a559e387d0d8749550 (patch) | |
tree | b21466db0750a99f59a8854ac79f11596b7f8b40 /LuaSL | |
parent | llSameGroup() returns integer, not key. I was only guessing before, actually... (diff) | |
download | SledjHamr-5d79985fe7d3873f9d4a82a559e387d0d8749550.zip SledjHamr-5d79985fe7d3873f9d4a82a559e387d0d8749550.tar.gz SledjHamr-5d79985fe7d3873f9d4a82a559e387d0d8749550.tar.bz2 SledjHamr-5d79985fe7d3873f9d4a82a559e387d0d8749550.tar.xz |
Implement assignments.
Diffstat (limited to 'LuaSL')
-rw-r--r-- | LuaSL/src/LuaSL_lemon_yaccer.y | 14 |
1 files changed, 7 insertions, 7 deletions
diff --git a/LuaSL/src/LuaSL_lemon_yaccer.y b/LuaSL/src/LuaSL_lemon_yaccer.y index 38b9c36..71caaa1 100644 --- a/LuaSL/src/LuaSL_lemon_yaccer.y +++ b/LuaSL/src/LuaSL_lemon_yaccer.y | |||
@@ -161,13 +161,13 @@ expr(A) ::= identifier(B). { A = B; } | |||
161 | 161 | ||
162 | %right LSL_ASSIGNMENT_CONCATENATE LSL_ASSIGNMENT_ADD LSL_ASSIGNMENT_SUBTRACT LSL_ASSIGNMENT_MULTIPLY LSL_ASSIGNMENT_MODULO LSL_ASSIGNMENT_DIVIDE LSL_ASSIGNMENT_PLAIN. | 162 | %right LSL_ASSIGNMENT_CONCATENATE LSL_ASSIGNMENT_ADD LSL_ASSIGNMENT_SUBTRACT LSL_ASSIGNMENT_MULTIPLY LSL_ASSIGNMENT_MODULO LSL_ASSIGNMENT_DIVIDE LSL_ASSIGNMENT_PLAIN. |
163 | // Yes, these can be expressions, and can happen in if statements and such. | 163 | // Yes, these can be expressions, and can happen in if statements and such. |
164 | expr(A) ::= identifier LSL_ASSIGNMENT_CONCATENATE expr(B). { A = B; } | 164 | expr(A) ::= identifier(B) LSL_ASSIGNMENT_CONCATENATE(C) expr(D). { A = addOperation(compiler, B, C, D); } |
165 | expr(A) ::= identifier LSL_ASSIGNMENT_ADD expr(B). { A = B; } | 165 | expr(A) ::= identifier(B) LSL_ASSIGNMENT_ADD(C) expr(D). { A = addOperation(compiler, B, C, D); } |
166 | expr(A) ::= identifier LSL_ASSIGNMENT_SUBTRACT expr(B) . { A = B; } | 166 | expr(A) ::= identifier(B) LSL_ASSIGNMENT_SUBTRACT(C) expr(D) . { A = addOperation(compiler, B, C, D); } |
167 | expr(A) ::= identifier LSL_ASSIGNMENT_MULTIPLY expr(B). { A = B; } | 167 | expr(A) ::= identifier(B) LSL_ASSIGNMENT_MULTIPLY(C) expr(D). { A = addOperation(compiler, B, C, D); } |
168 | expr(A) ::= identifier LSL_ASSIGNMENT_MODULO expr(B). { A = B; } | 168 | expr(A) ::= identifier(B) LSL_ASSIGNMENT_MODULO(C) expr(D). { A = addOperation(compiler, B, C, D); } |
169 | expr(A) ::= identifier LSL_ASSIGNMENT_DIVIDE expr(B). { A = B; } | 169 | expr(A) ::= identifier(B) LSL_ASSIGNMENT_DIVIDE(C) expr(D). { A = addOperation(compiler, B, C, D); } |
170 | expr(A) ::= identifier LSL_ASSIGNMENT_PLAIN expr(B). { A = B; } | 170 | expr(A) ::= identifier(B) LSL_ASSIGNMENT_PLAIN(C) expr(D). { A = addOperation(compiler, B, C, D); } |
171 | 171 | ||
172 | // Hmm think this can have commas seperating the assignment parts, or is that only in C?. If so, best to separate them when converting to Lua, as it uses that syntax for something else. | 172 | // Hmm think this can have commas seperating the assignment parts, or is that only in C?. If so, best to separate them when converting to Lua, as it uses that syntax for something else. |
173 | // Well, not in OpenSim at least, nor in SL. So we are safe. B-) | 173 | // Well, not in OpenSim at least, nor in SL. So we are safe. B-) |