fix small regressions in std.event
parent
ad0871ea4b
commit
7fa59565d3
|
@ -26,7 +26,7 @@ pub fn Future(comptime T: type) type {
|
||||||
pub fn init() Self {
|
pub fn init() Self {
|
||||||
return Self{
|
return Self{
|
||||||
.lock = Lock.initLocked(),
|
.lock = Lock.initLocked(),
|
||||||
.available = 0,
|
.available = .NotStarted,
|
||||||
.data = undefined,
|
.data = undefined,
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
|
@ -67,10 +67,10 @@ pub fn Group(comptime ReturnType: type) type {
|
||||||
.next = undefined,
|
.next = undefined,
|
||||||
.data = Node{
|
.data = Node{
|
||||||
.handle = frame,
|
.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);
|
self.alloc_stack.push(node);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue