一个表只能有一个元表,如果多次赋值,后赋的元表会覆盖之前的





注:换一种理解方式可以是设置成功了,但是元表(通过getmetatable获取不到)里没有其它任何键值

--- If `object` does not have a metatable, returns **nil**. Otherwise, if the
--- object's metatable has a `"__metatable"` field, returns the associated
--- value. Otherwise, returns the metatable of the given object.
---@param object any
---@return any
function getmetatable(object) end

被使用__metatable保护元表的表不能再修改元表,否则会报错cannot change a protected metatable


总结:__metatable可用于保护一个表让用户看不到和不能修改它的元表