comparison util/multitable.lua @ 1112:e8a00a2ea910

Merge with 0.4
author Matthew Wild <mwild1@gmail.com>
date Mon, 04 May 2009 19:57:05 +0100
parents e9c1650054c4
children 841d61be198f
comparison
equal deleted inserted replaced
1103:b78b1524eb79 1112:e8a00a2ea910
54 if n == _end then 54 if n == _end then
55 t[k] = nil; 55 t[k] = nil;
56 return; 56 return;
57 end 57 end
58 if k then 58 if k then
59 v = t[k]; 59 local v = t[k];
60 if v then 60 if v then
61 r(v, n+1, _end, ...); 61 r(v, n+1, _end, ...);
62 if not next(v) then 62 if not next(v) then
63 t[k] = nil; 63 t[k] = nil;
64 end 64 end
94 t_insert(results, t[k]); 94 t_insert(results, t[k]);
95 end 95 end
96 return; 96 return;
97 end 97 end
98 if k then 98 if k then
99 v = t[k]; 99 local v = t[k];
100 if v then 100 if v then
101 s(v, n+1, results, _end, ...); 101 s(v, n+1, results, _end, ...);
102 end 102 end
103 else 103 else
104 for _,b in pairs(t) do 104 for _,b in pairs(t) do