lua

A copy of the Lua development repository
Log | Files | Refs | README

commit 3d19aee78f7f9140548bd550559092eeff837409
parent 4194de70e72cd7048872463308f5a9a34bf994dc
Author: Roberto Ierusalimschy <roberto@inf.puc-rio.br>
Date:   Mon, 20 Dec 2004 13:49:38 -0200

`luac' may generate code without upvalue names

Diffstat:
Mldebug.c | 4++--
1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/ldebug.c b/ldebug.c @@ -1,5 +1,5 @@ /* -** $Id: ldebug.c,v 2.10 2004/10/07 17:27:00 roberto Exp roberto $ +** $Id: ldebug.c,v 2.11 2004/12/03 20:35:33 roberto Exp roberto $ ** Debug Interface ** See Copyright Notice in lua.h */ @@ -477,7 +477,7 @@ static const char *getobjname (CallInfo *ci, int stackpos, const char **name) { } case OP_GETUPVAL: { int u = GETARG_B(i); /* upvalue index */ - *name = getstr(p->upvalues[u]); + *name = p->upvalues ? getstr(p->upvalues[u]) : "?"; return "upvalue"; } case OP_SELF: {