more clever allocator save

This commit is contained in:
p.kosyh 2009-10-21 05:33:20 +00:00
parent 5cc1ad8c7d
commit 0c72491b69

View file

@ -1687,11 +1687,15 @@ allocator = obj {
local v = ref(n);
v.save = allocator_save;
v.constructor = n;
stead.table.insert(s._objects, v);
v.key_name = 'allocator._objects['..stead.table.maxn(s._objects)..']';
stead.table.insert(s.objects, v);
v.key_name = 'allocator.objects['..stead.table.maxn(s.objects)..']';
return v
end,
_objects = {},
objects = {
save = function(self, name, h, need)
savemembers(h, self, name, true);
end
},
};
function new(str)