[compiler-rt] d24d4b6 - [sanitizer] Add missing bitcast to sanitizer_bitvector_test.cpp (#192090)

via llvm-commits llvm-commits at lists.llvm.org
Tue Apr 14 10:22:38 PDT 2026


Author: Thurston Dang
Date: 2026-04-14T10:22:30-07:00
New Revision: d24d4b64e81ca3a2161772886a05a16ed8927080

URL: https://github.com/llvm/llvm-project/commit/d24d4b64e81ca3a2161772886a05a16ed8927080
DIFF: https://github.com/llvm/llvm-project/commit/d24d4b64e81ca3a2161772886a05a16ed8927080.diff

LOG: [sanitizer] Add missing bitcast to sanitizer_bitvector_test.cpp (#192090)

Fixes buildbot report
(https://lab.llvm.org/buildbot/#/builders/66/builds/29379):


/home/b/sanitizer-x86_64-linux/build/llvm-project/compiler-rt/lib/sanitizer_common/tests/sanitizer_bitvector_test.cpp:64:29:
error: format specifies type 'unsigned long' but the argument has type
'uptr' (aka 'unsigned int') [-Werror,-Wformat]
   64 |     fprintf(stderr, "%lu ", idx);
      |                      ~~~    ^~~
      |                      %u

Added: 
    

Modified: 
    compiler-rt/lib/sanitizer_common/tests/sanitizer_bitvector_test.cpp

Removed: 
    


################################################################################
diff  --git a/compiler-rt/lib/sanitizer_common/tests/sanitizer_bitvector_test.cpp b/compiler-rt/lib/sanitizer_common/tests/sanitizer_bitvector_test.cpp
index 9f51d0cb0c68e..dc22dfd59fd90 100644
--- a/compiler-rt/lib/sanitizer_common/tests/sanitizer_bitvector_test.cpp
+++ b/compiler-rt/lib/sanitizer_common/tests/sanitizer_bitvector_test.cpp
@@ -61,7 +61,7 @@ void Print(const BV &bv) {
   t.copyFrom(bv);
   while (!t.empty()) {
     uptr idx = t.getAndClearFirstOne();
-    fprintf(stderr, "%lu ", idx);
+    fprintf(stderr, "%lu ", (unsigned long)idx);
   }
   fprintf(stderr, "\n");
 }


        


More information about the llvm-commits mailing list