Commit Graph

6 Commits

Author SHA1 Message Date
Max Cahill
3cc177a0c0 BREAKING class interface refactor - all classes will need a minor update, see class.lua
tl;dr is that new no longer needs to call init, calling :new() directly in user code is not allowed, properties are copied, metamethods work, and a config table is needed rather than a class to extend from, so use {extends = superclass} if you want a minimal fix
2021-07-15 16:15:27 +10:00
Max Cahill
c2a9d39bcf [added] set.clear which does what you'd expect 2021-05-04 10:38:07 +10:00
Max Cahill
699affd1ad [added] set:size and set:get(index) 2020-08-29 21:12:56 +10:00
Max Cahill
028b21ef9a [added] set:to_table which returns the ordered contents unchanged and intentionally disables the set object itself 2020-08-24 20:54:24 +10:00
Max Cahill
6f0945a675 [added] set:values_readonly() to avoid a copy if you only need readonly access, with a note about safety 2020-05-02 20:12:59 +10:00
Max Cahill
e5be0df492 [added] set module with full (-ish?) suite of set operations and efficient (non-linear) membership testing
closes #4
2020-05-02 19:59:02 +10:00