luau
luau copied to clipboard
Passing a locally-bound format string to `string.format` produces an incorrect error
--!strict
local key = "Hello, %s!"
local fmt = key:format("world")
local fmt = string.format(key, "world")
-- both: Type Error - Function string.format expects 1 argument but 0 are specified