diff options
author | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 1998-03-25 15:52:29 -0300 |
---|---|---|
committer | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 1998-03-25 15:52:29 -0300 |
commit | 2a2b64d6ac2ea7839dac41cc84be1c7a5a18bee7 (patch) | |
tree | bbacd86c6e92e3614dcd48b54846de5f4252f137 /lua.stx | |
parent | daa937c043bb0ddb5f4bfe676f8ff13825a99651 (diff) | |
download | lua-2a2b64d6ac2ea7839dac41cc84be1c7a5a18bee7.tar.gz lua-2a2b64d6ac2ea7839dac41cc84be1c7a5a18bee7.tar.bz2 lua-2a2b64d6ac2ea7839dac41cc84be1c7a5a18bee7.zip |
opcode "CLOSURE" gets the prototipe (instead of a previous pushconstant)
Diffstat (limited to 'lua.stx')
-rw-r--r-- | lua.stx | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -1,6 +1,6 @@ | |||
1 | %{ | 1 | %{ |
2 | /* | 2 | /* |
3 | ** $Id: lua.stx,v 1.34 1998/02/11 20:56:46 roberto Exp roberto $ | 3 | ** $Id: lua.stx,v 1.35 1998/03/09 21:49:52 roberto Exp roberto $ |
4 | ** Syntax analizer and code generator | 4 | ** Syntax analizer and code generator |
5 | ** See Copyright Notice in lua.h | 5 | ** See Copyright Notice in lua.h |
6 | */ | 6 | */ |
@@ -554,8 +554,8 @@ static void func_onstack (TProtoFunc *f) | |||
554 | else { | 554 | else { |
555 | for (i=0; i<nupvalues; i++) | 555 | for (i=0; i<nupvalues; i++) |
556 | lua_pushvar((L->currState+1)->upvalues[i]); | 556 | lua_pushvar((L->currState+1)->upvalues[i]); |
557 | code_constant(c); | 557 | code_oparg(CLOSURE, 0, c, -nupvalues+1); |
558 | code_oparg(CLOSURE, 2, nupvalues, -nupvalues); | 558 | code_byte(nupvalues); |
559 | } | 559 | } |
560 | } | 560 | } |
561 | 561 | ||