authorgravatar for andrew@ziglang.orgAndrew Kelley <andrew@ziglang.org> 2019-07-02 19:44:49-04:00
committergravatar for andrew@ziglang.orgAndrew Kelley <andrew@ziglang.org> 2019-07-02 19:44:49-04:00
logb84ff1dd325b14bc4a6fc37109b5af8203e6a517
tree8cbde2c28ddd61e845a2f51ebdb8eaf444ff7723
parent57d6724186ead79ac76491f42390c0d581a76b04
signaturelock-open Commit is signed but in an unrecognized format.

update the default panic handler on freestanding

Now the infinite loop has a `@breakpoint()` in there.

1 files changed, 3 insertions(+), 1 deletions(-)

std/special/panic.zig+3-1
...@@ -10,7 +10,9 @@ pub fn panic(msg: []const u8, error_return_trace: ?*builtin.StackTrace) noreturn...@@ -10,7 +10,9 @@ pub fn panic(msg: []const u8, error_return_trace: ?*builtin.StackTrace) noreturn
10 @setCold(true);10 @setCold(true);
11 switch (builtin.os) {11 switch (builtin.os) {
12 .freestanding => {12 .freestanding => {
13 while (true) {}13 while (true) {
14 @breakpoint();
15 }
14 },16 },
15 .wasi => {17 .wasi => {
16 std.debug.warn("{}", msg);18 std.debug.warn("{}", msg);