Skip to content

Commit

Permalink
Add lua_resume error check
Browse files Browse the repository at this point in the history
  • Loading branch information
axstin committed May 24, 2022
1 parent 6da0cc0 commit 8d0b283
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions tests/conformance/errors.lua
Original file line number Diff line number Diff line change
Expand Up @@ -230,6 +230,11 @@ if not limitedstack then
ehassert(pcall(function() return userdata[1] end)) -- LOP_GETTABLEN
ehassert(pcall(function() return userdata.StringConstant end)) -- LOP_GETTABLEKS (luau_callTM)

-- lua_resume test
local coro = coroutine.create(function() end)
ps, pe = coroutine.resume(coro)
ehassert(not ps and string.find(pe, "C stack overflow"))

return true
end, cso)

Expand Down

0 comments on commit 8d0b283

Please sign in to comment.