Commit 9b5737b5a6

Daniele Cocca <daniele.cocca@gmail.com>
2022-03-13 12:52:58
s/testClz/testCtz/g
The test name here was likely the result of a bad copy-paste, as the test code is actually testing for trailing zeroes, not leading zeroes.
1 parent 47e004d
Changed files (1)
test
behavior
test/behavior/bugs/2114.zig
@@ -7,11 +7,11 @@ fn ctz(x: anytype) usize {
 }
 
 test "fixed" {
-    try testClz();
-    comptime try testClz();
+    try testCtz();
+    comptime try testCtz();
 }
 
-fn testClz() !void {
+fn testCtz() !void {
     try expect(ctz(@as(u128, 0x40000000000000000000000000000000)) == 126);
     try expect(math.rotl(u128, @as(u128, 0x40000000000000000000000000000000), @as(u8, 1)) == @as(u128, 0x80000000000000000000000000000000));
     try expect(ctz(@as(u128, 0x80000000000000000000000000000000)) == 127);