aboutsummaryrefslogtreecommitdiff
path: root/src/lock.zig
diff options
context:
space:
mode:
Diffstat (limited to 'src/lock.zig')
-rw-r--r--src/lock.zig2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/lock.zig b/src/lock.zig
index 7e6bfccdf..66d64cff2 100644
--- a/src/lock.zig
+++ b/src/lock.zig
@@ -24,7 +24,7 @@ pub const Mutex = struct {
inline fn acquireFast(self: *Mutex, comptime strong: bool) bool {
// On x86, "lock bts" uses less i-cache & can be faster than "lock cmpxchg" below.
if (comptime is_x86) {
- return self.state.bitSet(@ctz(u32, LOCKED), .Acquire) == UNLOCKED;
+ return self.state.bitSet(@ctz(@as(u32, LOCKED)), .Acquire) == UNLOCKED;
}
const cas_fn = comptime switch (strong) {