luau icon indicating copy to clipboard operation
luau copied to clipboard

Passing a locally-bound format string to `string.format` produces an incorrect error

Open imnerolin opened this issue 1 year ago • 0 comments

--!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

imnerolin avatar Dec 19 '24 02:12 imnerolin