diff options
| author | Jacob Young <jacobly0@users.noreply.github.com> | 2024-03-19 12:46:38 +0100 |
|---|---|---|
| committer | Jacob Young <jacobly0@users.noreply.github.com> | 2024-03-30 20:50:48 -0400 |
| commit | eb723a407073592db858cf14bece8643bec2a771 (patch) | |
| tree | 504be71818a397d2b8ce07aa26718b5c7a5b7ef5 /lib/std/Thread/Pool.zig | |
| parent | 17673dcd6e3ffeb25fc9dc1cfc72334ab4e71b37 (diff) | |
| download | zig-eb723a407073592db858cf14bece8643bec2a771.tar.gz zig-eb723a407073592db858cf14bece8643bec2a771.zip | |
Update uses of `@fieldParentPtr` to use RLS
Diffstat (limited to 'lib/std/Thread/Pool.zig')
| -rw-r--r-- | lib/std/Thread/Pool.zig | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lib/std/Thread/Pool.zig b/lib/std/Thread/Pool.zig index 9f386c8e65..a96b4255e2 100644 --- a/lib/std/Thread/Pool.zig +++ b/lib/std/Thread/Pool.zig @@ -88,8 +88,8 @@ pub fn spawn(pool: *Pool, comptime func: anytype, args: anytype) !void { run_node: RunQueue.Node = .{ .data = .{ .runFn = runFn } }, fn runFn(runnable: *Runnable) void { - const run_node = @fieldParentPtr(*RunQueue.Node, "data", runnable); - const closure = @fieldParentPtr(*@This(), "run_node", run_node); + const run_node: *RunQueue.Node = @fieldParentPtr("data", runnable); + const closure: *@This() = @fieldParentPtr("run_node", run_node); @call(.auto, func, closure.arguments); // The thread pool's allocator is protected by the mutex. |
