From 99b3623834113e86b4302c2027a0422a2cdd09c3 Mon Sep 17 00:00:00 2001 From: daurnimator Date: Mon, 8 May 2017 18:16:22 +1000 Subject: src/lapi.js: Be consistent with aux_upvalue return type --- src/lapi.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/lapi.js') diff --git a/src/lapi.js b/src/lapi.js index 64cb4e1..bf62931 100644 --- a/src/lapi.js +++ b/src/lapi.js @@ -502,7 +502,7 @@ const aux_upvalue = function(L, fi, n) { let f = fi.value; if (!(1 <= n && n <= f.nupvalues)) return null; return { - name: "", + name: [], val: f.upvalue[n-1] }; } @@ -512,7 +512,7 @@ const aux_upvalue = function(L, fi, n) { if (!(1 <= n && n <= p.upvalues.length)) return null; let name = p.upvalues[n-1].name; return { - name: name ? name : "(*no name)", + name: name ? name : defs.to_luastring("(*no name)", true), val: f.upvals[n-1].val() }; } -- cgit v1.2.3-70-g09d2