| ... | @@ -796,9 +796,10 @@ pub const Loop = struct { | ... | @@ -796,9 +796,10 @@ pub const Loop = struct { |
| 796 | .waiters = DelayQueue.Waiters{ | 796 | .waiters = DelayQueue.Waiters{ |
| 797 | .entries = std.atomic.Queue(anyframe).init(), | 797 | .entries = std.atomic.Queue(anyframe).init(), |
| 798 | }, | 798 | }, |
| 799 | .thread = try std.Thread.spawn(self, DelayQueue.run), | | |
| 800 | .event = std.AutoResetEvent{}, | 799 | .event = std.AutoResetEvent{}, |
| 801 | .is_running = true, | 800 | .is_running = true, |
| | 801 | // Must be last so that it can read the other state, such as `is_running`. |
| | 802 | .thread = try std.Thread.spawn(self, DelayQueue.run), |
| 802 | }; | 803 | }; |
| 803 | } | 804 | } |
| 804 | | 805 | |