aboutsummaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorAndrew Kelley <andrew@ziglang.org>2022-07-26 20:12:40 -0700
committerAndrew Kelley <andrew@ziglang.org>2022-07-26 20:12:40 -0700
commitbdaa915a02eefe2fb2e400069fcb79b41dcabb94 (patch)
tree74df0e101e5a24610f30694b6c473d3f8e2cf565 /test
parentacf1aa10c2dcd485496c0db1d9c5378b2c23dd96 (diff)
downloadzig-bdaa915a02eefe2fb2e400069fcb79b41dcabb94.tar.gz
zig-bdaa915a02eefe2fb2e400069fcb79b41dcabb94.zip
test-cases: remove failing test
This causes a stack overflow in a debug build of stage3 unfortunately. I will open an issue to track this test coverage, which we absolutely should get working - users of the compiler should get a compile error, not a segfault if they hit the default branch quota from abusing recursive inline functions. Note that the problem does not occur in a release build of stage3 which has significantly reduced stack usage. On Linux, I tried bumping up the stack size from 32 MiB to 64 MiB and it did not solve the problem. I'm not sure why not. It seems like it should be fine. Note that we also have a problem of running test-cases in multi-threaded mode which is currently the default. Currently Zig threads are spawned with 16 MiB stack space.
Diffstat (limited to 'test')
-rw-r--r--test/cases/compile_errors/endless_loop_in_function_evaluation.zig15
1 files changed, 0 insertions, 15 deletions
diff --git a/test/cases/compile_errors/endless_loop_in_function_evaluation.zig b/test/cases/compile_errors/endless_loop_in_function_evaluation.zig
deleted file mode 100644
index 7616bfa5e7..0000000000
--- a/test/cases/compile_errors/endless_loop_in_function_evaluation.zig
+++ /dev/null
@@ -1,15 +0,0 @@
-const seventh_fib_number = fibonacci(7);
-fn fibonacci(x: i32) i32 {
- return fibonacci(x - 1) + fibonacci(x - 2);
-}
-
-export fn entry() usize { return @sizeOf(@TypeOf(&seventh_fib_number)); }
-
-// error
-// backend=stage2
-// target=native
-//
-// :3:21: error: evaluation exceeded 1000 backwards branches
-// :3:21: note: use @setEvalBranchQuota() to raise the branch limit from 1000
-// :3:21: note: called from here (999 times)
-// :1:37: note: called from here