# HG changeset patch # User Kim Alvefur # Date 1518765795 -3600 # Node ID 6f5ce0f09f409ea8b8f648f4b9ee16c145853298 # Parent e959bc51de75522d5ffa01a6552e40f6869beefd util.array: Add a __name field to metatable diff -r e959bc51de75 -r 6f5ce0f09f40 util/array.lua --- a/util/array.lua Fri Feb 16 08:16:38 2018 +0100 +++ b/util/array.lua Fri Feb 16 08:23:15 2018 +0100 @@ -19,7 +19,7 @@ local array = {}; local array_base = {}; local array_methods = {}; -local array_mt = { __index = array_methods, __tostring = function (self) return "{"..self:concat(", ").."}"; end }; +local array_mt = { __index = array_methods, __name = "array", __tostring = function (self) return "{"..self:concat(", ").."}"; end }; local function new_array(self, t, _s, _var) if type(t) == "function" then -- Assume iterator