From 4306e5ae0c2a31ea6798af41f7033771af9af6d5 Mon Sep 17 00:00:00 2001 From: "Justin M. Keyes" Date: Tue, 28 Feb 2017 17:39:23 +0100 Subject: test: luacheck update We pull luacheck HEAD, so this is a "catch up" commit to fix newly-discovered errors. --- test/unit/api/helpers.lua | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'test/unit/api/helpers.lua') diff --git a/test/unit/api/helpers.lua b/test/unit/api/helpers.lua index 883e1c6c19..166456d2a1 100644 --- a/test/unit/api/helpers.lua +++ b/test/unit/api/helpers.lua @@ -106,7 +106,8 @@ local lua2obj_type_tab = { api.xmalloc(len * ffi.sizeof('KeyValuePair'))), }}) for i = 1, len do - local key, val = table.unpack(kvs[i]) + local table_unpack = table.unpack or unpack -- luacheck: compat + local key, val = table_unpack(kvs[i]) dct.data.dictionary.items[i - 1] = ffi.new( 'KeyValuePair', {key=ffi.gc(lua2obj(key), nil).data.string, value=ffi.gc(lua2obj(val), nil)}) -- cgit