(Fix #37) Copy metatable in class:clone()

This commit is contained in:
Matthias Richter 2014-08-22 13:51:25 +02:00
parent e8af2a6ec2
commit 4f53485fb7

View File

@ -51,7 +51,7 @@ end
-- returns a deep copy of `other'
local function clone(other)
return include({}, other)
return setmetatable(include({}, other), getmetatable(other))
end
local function new(class)