# HG changeset patch # User Matthew Wild # Date 1378207303 -3600 # Node ID 6e087f3b8f3b3bb5e0268f329e5ce9f7214b182c # Parent 5cf1c08805fbd7ad06bcee919d04a7f9acf95b8b util.set: :items() now returns an iterator instead of the underlying table. This is much more efficient than 'for item in set' (which still works for now). Current access to _items is generally done directly, this may change. diff -r 5cf1c08805fb -r 6e087f3b8f3b util/set.lua --- a/util/set.lua Tue Sep 03 00:20:28 2013 +0100 +++ b/util/set.lua Tue Sep 03 12:21:43 2013 +0100 @@ -75,7 +75,7 @@ end function set:items() - return items; + return next, items; end function set:remove(item)