aboutsummaryrefslogtreecommitdiff
path: root/testes
diff options
context:
space:
mode:
Diffstat (limited to '')
-rw-r--r--testes/calls.lua10
1 files changed, 10 insertions, 0 deletions
diff --git a/testes/calls.lua b/testes/calls.lua
index ff72d8f6..ee8cce73 100644
--- a/testes/calls.lua
+++ b/testes/calls.lua
@@ -151,6 +151,16 @@ do -- tail calls x varargs
151end 151end
152 152
153 153
154do -- C-stack overflow while handling C-stack overflow
155 local function loop ()
156 assert(pcall(loop))
157 end
158
159 local err, msg = xpcall(loop, loop)
160 assert(not err and string.find(msg, "error"))
161end
162
163
154 164
155do -- tail calls x chain of __call 165do -- tail calls x chain of __call
156 local n = 10000 -- depth 166 local n = 10000 -- depth