-
-
Save jamii/fb39e1d2f07f26642b63fbe127033812 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
[nix-shell:~/bounded-live-eval]$ zig run main.zig | |
thread 7417 panic: awaiting function resumed | |
/home/jamie/bounded-live-eval/main.zig:6:6: 0x22ffe3 in b (main) | |
a(); | |
^ | |
/home/jamie/bounded-live-eval/main.zig:14:5: 0x22920f in main (main) | |
resume b_frame; | |
^ | |
/nix/store/7wdppz5pss576bn60rl053ihwx7v635i-zig/lib/std/start.zig:410:22: 0x221bec in std.start.callMain (main) | |
root.main(); | |
^ | |
/nix/store/7wdppz5pss576bn60rl053ihwx7v635i-zig/lib/std/start.zig:362:12: 0x205b3e in std.start.callMainWithArgs (main) | |
return @call(.{ .modifier = .always_inline }, callMain, .{}); | |
^ | |
/nix/store/7wdppz5pss576bn60rl053ihwx7v635i-zig/lib/std/start.zig:316:17: 0x204dc9 in std.start.posixCallMainAndExit (main) | |
std.os.exit(@call(.{ .modifier = .always_inline }, callMainWithArgs, .{ argc, argv, envp })); | |
^ | |
/nix/store/7wdppz5pss576bn60rl053ihwx7v635i-zig/lib/std/start.zig:238:5: 0x204cf2 in std.start._start (main) | |
@call(.{ .modifier = .never_inline }, posixCallMainAndExit, .{}); | |
^ | |
Aborted (core dumped) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
fn a() void { | |
suspend {} | |
} | |
fn b() void { | |
a(); | |
} | |
pub fn main() void { | |
// this works fine | |
var a_frame = async a(); | |
resume a_frame; | |
// this panics | |
var b_frame = async b(); | |
resume b_frame; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment