Skip to content

Commit

Permalink
tests: add a non-regression test for return arity edge case (#892)
Browse files Browse the repository at this point in the history
Fixes #741 (fixed in Teal 0.24.0)
  • Loading branch information
catwell authored Jan 3, 2025
1 parent 0a6294e commit 3bfa31b
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions spec/lang/statement/return_spec.lua
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,14 @@ describe("return", function()
return bar()
end
]], {}))

it("with zero (regression test for #741)", util.check([[
local function bar() end
local function foo()
return bar()
end
]]))
end)

describe("type checking", function()
Expand Down

0 comments on commit 3bfa31b

Please sign in to comment.