diff options
| author | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2005-10-23 15:37:55 -0200 |
|---|---|---|
| committer | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2005-10-23 15:37:55 -0200 |
| commit | 502d8f9a06b85c7a8a0e74a27d6738d92969b9a7 (patch) | |
| tree | 6e4b43339ff1098c0a92e3ee015c096c83d50a4b | |
| parent | 7f376e6ea88e218ba74137efaa5f84b837d8e277 (diff) | |
| download | lua-502d8f9a06b85c7a8a0e74a27d6738d92969b9a7.tar.gz lua-502d8f9a06b85c7a8a0e74a27d6738d92969b9a7.tar.bz2 lua-502d8f9a06b85c7a8a0e74a27d6738d92969b9a7.zip | |
comments
| -rw-r--r-- | lopcodes.h | 10 |
1 files changed, 5 insertions, 5 deletions
| @@ -1,5 +1,5 @@ | |||
| 1 | /* | 1 | /* |
| 2 | ** $Id: lopcodes.h,v 1.121 2005/06/06 13:30:25 roberto Exp $ | 2 | ** $Id: lopcodes.h,v 1.122 2005/08/29 20:49:21 roberto Exp roberto $ |
| 3 | ** Opcodes for Lua virtual machine | 3 | ** Opcodes for Lua virtual machine |
| 4 | ** See Copyright Notice in lua.h | 4 | ** See Copyright Notice in lua.h |
| 5 | */ | 5 | */ |
| @@ -193,12 +193,12 @@ OP_CALL,/* A B C R(A), ... ,R(A+C-2) := R(A)(R(A+1), ... ,R(A+B-1)) */ | |||
| 193 | OP_TAILCALL,/* A B C return R(A)(R(A+1), ... ,R(A+B-1)) */ | 193 | OP_TAILCALL,/* A B C return R(A)(R(A+1), ... ,R(A+B-1)) */ |
| 194 | OP_RETURN,/* A B return R(A), ... ,R(A+B-2) (see note) */ | 194 | OP_RETURN,/* A B return R(A), ... ,R(A+B-2) (see note) */ |
| 195 | 195 | ||
| 196 | OP_FORLOOP,/* A sBx R(A)+=R(A+2); if R(A) <?= R(A+1) then pc+=sBx */ | 196 | OP_FORLOOP,/* A sBx R(A)+=R(A+2); |
| 197 | if R(A) <?= R(A+1) then { pc+=sBx; R(A+3)=R(A) }*/ | ||
| 197 | OP_FORPREP,/* A sBx R(A)-=R(A+2); pc+=sBx */ | 198 | OP_FORPREP,/* A sBx R(A)-=R(A+2); pc+=sBx */ |
| 198 | 199 | ||
| 199 | OP_TFORLOOP,/* A C R(A+2), ... ,R(A+2+C) := R(A)(R(A+1), R(A+2)); | 200 | OP_TFORLOOP,/* A C R(A+3), ... ,R(A+3+C) := R(A)(R(A+1), R(A+2)); |
| 200 | if R(A+2) ~= nil then pc++ */ | 201 | if R(A+3) ~= nil then { pc++; R(A+2)=R(A+3); } */ |
| 201 | |||
| 202 | OP_SETLIST,/* A B C R(A)[(C-1)*FPF+i] := R(A+i), 1 <= i <= B */ | 202 | OP_SETLIST,/* A B C R(A)[(C-1)*FPF+i] := R(A+i), 1 <= i <= B */ |
| 203 | 203 | ||
| 204 | OP_CLOSE,/* A close all variables in the stack up to (>=) R(A)*/ | 204 | OP_CLOSE,/* A close all variables in the stack up to (>=) R(A)*/ |
