[PATCH] D74039: Make llvm::crc32() work also for input sizes larger than 32 bits.
Hans Wennborg via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Wed Feb 5 04:46:27 PST 2020
hans added a comment.
I was curious if it would be possible to enable the warning for this:
diff --git a/llvm/cmake/modules/HandleLLVMOptions.cmake b/llvm/cmake/modules/HandleLLVMOptions.cmake
index cd48f93f80c..5ec735d9c63 100644
--- a/llvm/cmake/modules/HandleLLVMOptions.cmake
+++ b/llvm/cmake/modules/HandleLLVMOptions.cmake
@@ -663,6 +663,9 @@ if (LLVM_ENABLE_WARNINGS AND (LLVM_COMPILER_IS_GCC_COMPATIBLE OR CLANG_CL))
# Enable -Wstring-conversion to catch misuse of string literals.
add_flag_if_supported("-Wstring-conversion" STRING_CONVERSION_FLAG)
+
+ # Enable -Wshorten-64-to-32.
+ add_flag_if_supported("-Wshorten-64-to-32" SHORTEN_64_TO_32)
endif (LLVM_ENABLE_WARNINGS AND (LLVM_COMPILER_IS_GCC_COMPATIBLE OR CLANG_CL))
if (LLVM_COMPILER_IS_GCC_COMPATIBLE AND NOT LLVM_ENABLE_WARNINGS)
but sadly it seems LLVM relies on these conversions //a lot//.
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D74039/new/
https://reviews.llvm.org/D74039
More information about the llvm-commits
mailing list