Mercurial > prosody-hg
comparison util/multitable.lua @ 7185:5687788a2e4d
util.multitable: Localize unpack() in Lua 5.2 compatible way
| author | Kim Alvefur <zash@zash.se> |
|---|---|
| date | Mon, 22 Feb 2016 17:40:42 +0100 |
| parents | 5de6b93d0190 |
| children | e5d00bf4a4d5 |
comparison
equal
deleted
inserted
replaced
| 7184:dedc6bf180e2 | 7185:5687788a2e4d |
|---|---|
| 6 -- COPYING file in the source package for more information. | 6 -- COPYING file in the source package for more information. |
| 7 -- | 7 -- |
| 8 | 8 |
| 9 local select = select; | 9 local select = select; |
| 10 local t_insert = table.insert; | 10 local t_insert = table.insert; |
| 11 local unpack, pairs, next, type = unpack, pairs, next, type; | 11 local pairs, next, type = pairs, next, type; |
| 12 local unpack = table.unpack or unpack; --luacheck: ignore 113 | |
| 12 | 13 |
| 13 local _ENV = nil; | 14 local _ENV = nil; |
| 14 | 15 |
| 15 local function get(self, ...) | 16 local function get(self, ...) |
| 16 local t = self.data; | 17 local t = self.data; |
