util.set: Add luacheck annotation for methods not referencing 'self'
authorMatthew Wild <mwild1@gmail.com>
Wed, 6 May 2015 18:51:07 +0000 (19:51 +0100)
committerMatthew Wild <mwild1@gmail.com>
Wed, 6 May 2015 18:51:07 +0000 (19:51 +0100)
util/set.lua

index c160d28e79adf6123220f4b84fe7f99e0ca6de35..0a263440faf94d88fac7fbc48ba3fcda6b78c13e 100644 (file)
@@ -66,6 +66,9 @@ function new(list)
        local items = setmetatable({}, items_mt);
        local set = { _items = items };
 
+       -- We access the set through an upvalue in these methods, so ignore 'self' being unused
+       --luacheck: ignore 212/self
+
        function set:add(item)
                items[item] = true;
        end