Skip to content

setmetatable doesn't work after changing into require #361

Description

@jinwenhua

local test = {
test = "tst",
}
local Base = {}
setmetatable(Base, {__index = test})
Base can have the field test, if it is changed into code like this, it doesn't work
local test = require("abc")
local Base = {}
setmetatable(Base, {__index = test})

abc.lua contains code:
local test = {
test = "tst",
}
return test

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions