Lua's designers have a sort of maxim "if it can't be done perfectly, let the user roll their own". This can be frustrating, but for table-copying it's not surprising. Do you copy subtables by reference or value? What about recursive tables? Mutually recursive subtables? Closures in tables? And then userdata can contain references that are opaque to the language runtime. It's not easy to define the behavior of deep copy in the fully general case.
https://github.com/mikelovesrobots/lua-enumerable/blob/maste...
See: table.dup()
Lots of people obviously have a problem with this as it deeply different from the algebra derived assignment syntax.
local a = b creates a local copy, but even then, its not a deepcopy, containing references to other tables.
Maybe I'm just missing something. If I recall, I was simply trying to create a new 'object' (game character) from a template but it required metatable boiler plate that just made no sense to me.
Many languages, this is simply a = b, or at most allocating some space first.