Skip to content

Commit c5914d9

Browse files
committed
std: allow setmetable to take nil
Note Lua allows: ```lua setmetable({}, nil) ``` but does not allow: ```lua setmetable({}) ```
1 parent 6fc07b3 commit c5914d9

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

  • crates/emmylua_code_analysis/resources/std

crates/emmylua_code_analysis/resources/std/global.lua

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -375,7 +375,7 @@ function select(index, ...) end
375375
---
376376
--- This function returns `table`.
377377
---@param table table
378-
---@param metatable std.metatable|table
378+
---@param metatable std.metatable|table|nil
379379
---@return table
380380
function setmetatable(table, metatable) end
381381

0 commit comments

Comments
 (0)