diff options
author | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2017-12-15 11:07:10 -0200 |
---|---|---|
committer | Roberto Ierusalimschy <roberto@inf.puc-rio.br> | 2017-12-15 11:07:10 -0200 |
commit | b3f924bc695ed6ebe2539d365197696e41863a91 (patch) | |
tree | bf756351d06bdfc469846e533699c9ce58bc3566 /ldebug.c | |
parent | e001d5aea693ca1bcf1a4dfd2f900737fc0a8604 (diff) | |
download | lua-b3f924bc695ed6ebe2539d365197696e41863a91.tar.gz lua-b3f924bc695ed6ebe2539d365197696e41863a91.tar.bz2 lua-b3f924bc695ed6ebe2539d365197696e41863a91.zip |
'Proto->numparams' does not include vararg parameter
(one less subtraction when calling functions...)
Diffstat (limited to 'ldebug.c')
-rw-r--r-- | ldebug.c | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -1,5 +1,5 @@ | |||
1 | /* | 1 | /* |
2 | ** $Id: ldebug.c,v 2.147 2017/12/07 15:44:10 roberto Exp roberto $ | 2 | ** $Id: ldebug.c,v 2.148 2017/12/13 18:32:09 roberto Exp roberto $ |
3 | ** Debug Interface | 3 | ** Debug Interface |
4 | ** See Copyright Notice in lua.h | 4 | ** See Copyright Notice in lua.h |
5 | */ | 5 | */ |
@@ -328,7 +328,7 @@ static int auxgetinfo (lua_State *L, const char *what, lua_Debug *ar, | |||
328 | } | 328 | } |
329 | else { | 329 | else { |
330 | ar->isvararg = f->l.p->is_vararg; | 330 | ar->isvararg = f->l.p->is_vararg; |
331 | ar->nparams = f->l.p->numparams; | 331 | ar->nparams = f->l.p->numparams + f->l.p->is_vararg; |
332 | } | 332 | } |
333 | break; | 333 | break; |
334 | } | 334 | } |