# tables iterate in hash order\: iterator pairs[A, B](t: Table[A, B]): (A, B) = let L = len(t) for h in 0 .. high(t.data): if isFilled(t.data[h].hcode): yield (t.data[h].key, t.data[h].val) assert(len(t) == L, "the length of the table changed while iterating over it")