diff options
| author | Vexu <15308111+Vexu@users.noreply.github.com> | 2019-11-23 20:18:38 +0200 |
|---|---|---|
| committer | Andrew Kelley <andrew@ziglang.org> | 2019-11-23 14:01:00 -0500 |
| commit | 7fa59565d31d4bd62e7c1250bb6c8aeda83429e6 (patch) | |
| tree | 08c0c0dafeae120720223466b7fcd70c72d9fadc /lib/std/event | |
| parent | ad0871ea4bf2dfbed07282ffe14738b5347d5d32 (diff) | |
| download | zig-7fa59565d31d4bd62e7c1250bb6c8aeda83429e6.tar.gz zig-7fa59565d31d4bd62e7c1250bb6c8aeda83429e6.zip | |
fix small regressions in std.event
Diffstat (limited to 'lib/std/event')
| -rw-r--r-- | lib/std/event/future.zig | 2 | ||||
| -rw-r--r-- | lib/std/event/group.zig | 4 |
2 files changed, 3 insertions, 3 deletions
diff --git a/lib/std/event/future.zig b/lib/std/event/future.zig index 5261db990c..492582da75 100644 --- a/lib/std/event/future.zig +++ b/lib/std/event/future.zig @@ -26,7 +26,7 @@ pub fn Future(comptime T: type) type { pub fn init() Self { return Self{ .lock = Lock.initLocked(), - .available = 0, + .available = .NotStarted, .data = undefined, }; } diff --git a/lib/std/event/group.zig b/lib/std/event/group.zig index 77dd2cd1aa..2b26a500dd 100644 --- a/lib/std/event/group.zig +++ b/lib/std/event/group.zig @@ -67,10 +67,10 @@ pub fn Group(comptime ReturnType: type) type { .next = undefined, .data = Node{ .handle = frame, - .bytes = @sliceToBytes((*[1]@Frame(func))(frame)[0..]), + .bytes = std.mem.asBytes(frame), }, }; - frame.* = async func(args); + _ = @asyncCall(frame, {}, func, args); self.alloc_stack.push(node); } |
