Module:FunList/TableEnumerator: Revision history

From Melvor Idle

Diff selection: Mark the radio buttons of the revisions to compare and hit enter or the button at the bottom.
Legend: (cur) = difference with latest revision, (prev) = difference with preceding revision, m = minor edit.

26 July 2024

  • curprev 19:5719:57, 26 July 2024Ricewind talk contribs 2,209 bytes +2,209 Created page with "---A lightweight enumerator for tables in array form. ---@class ArrayEnumerator : Enumerator ---@field _tbl table ---@field current any ---@field index integer local ArrayEnumerator = {} ArrayEnumerator.__index = ArrayEnumerator function ArrayEnumerator.new(tbl) assert(tbl) local self = setmetatable({}, ArrayEnumerator) self._tbl = tbl self.current = nil self.index = 0 return self end function ArrayEnumerator:moveNext() local index = self.i..."