lua-language-server
lua-language-server copied to clipboard
[Feature Request] Automatically overload with `__call` metamethod.
There is already custom behavior when __index is defined in a metatable, why not __call? You can manually define the overload, but then you have to define the signature twice.
---@overload fun(a: string, b: number): boolean
local foo = setmetatable({}, {
---@param a string
---@param b number
---@return boolean
__call = function(a, b)
return true;
end
});