diff options
| author | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2017-11-03 10:12:30 -0200 |
|---|---|---|
| committer | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2017-11-03 10:12:30 -0200 |
| commit | 54eb35a8aa0f60265cf1b4764beabe1199d66f42 (patch) | |
| tree | 83bc4049d312bdbe0b8e78ed1745839fcf9a5a03 /lobject.h | |
| parent | ba36180fd7b68341ad57e0fbe7a55cdfb334908d (diff) | |
| download | lua-54eb35a8aa0f60265cf1b4764beabe1199d66f42.tar.gz lua-54eb35a8aa0f60265cf1b4764beabe1199d66f42.tar.bz2 lua-54eb35a8aa0f60265cf1b4764beabe1199d66f42.zip | |
more fields moved out of 'CallInfo'
Diffstat (limited to 'lobject.h')
| -rw-r--r-- | lobject.h | 13 |
1 files changed, 12 insertions, 1 deletions
| @@ -1,5 +1,5 @@ | |||
| 1 | /* | 1 | /* |
| 2 | ** $Id: lobject.h,v 2.125 2017/06/29 15:06:44 roberto Exp roberto $ | 2 | ** $Id: lobject.h,v 2.126 2017/10/31 17:54:35 roberto Exp roberto $ |
| 3 | ** Type definitions for Lua objects | 3 | ** Type definitions for Lua objects |
| 4 | ** See Copyright Notice in lua.h | 4 | ** See Copyright Notice in lua.h |
| 5 | */ | 5 | */ |
| @@ -313,10 +313,21 @@ typedef union StackValue { | |||
| 313 | TValue val; | 313 | TValue val; |
| 314 | struct { | 314 | struct { |
| 315 | TValuefields; | 315 | TValuefields; |
| 316 | lu_byte callstatus_; | ||
| 316 | unsigned short previous; /* difference to previous 'func' */ | 317 | unsigned short previous; /* difference to previous 'func' */ |
| 318 | short nresults; /* expected number of results from this function */ | ||
| 319 | unsigned short framesize; /* stack space available for this function */ | ||
| 317 | } stkci; | 320 | } stkci; |
| 318 | } StackValue; | 321 | } StackValue; |
| 319 | 322 | ||
| 323 | #define callstatus(ar) ((ar)->stkci.callstatus_) | ||
| 324 | |||
| 325 | /* top of a function (first element after its frame) */ | ||
| 326 | #define functop(func) ((func) + (func)->stkci.framesize) | ||
| 327 | |||
| 328 | /* set top of a function to a specific value */ | ||
| 329 | #define setfunctop(func,v) ((func)->stkci.framesize = (v) - (func)) | ||
| 330 | |||
| 320 | 331 | ||
| 321 | typedef StackValue *StkId; /* index to stack elements */ | 332 | typedef StackValue *StkId; /* index to stack elements */ |
| 322 | 333 | ||
