[llvm-commits] [llvm] r152021 - /llvm/trunk/include/llvm/ADT/Hashing.h

Sebastian Redl sebastian.redl at getdesigned.at
Mon Mar 5 02:28:02 PST 2012


On 05.03.2012 10:56, Chandler Carruth wrote:
> Author: chandlerc
> Date: Mon Mar  5 03:56:12 2012
> New Revision: 152021
>
> URL: http://llvm.org/viewvc/llvm-project?rev=152021&view=rev
> Log:
> Switch to a C-style cast here to silence a brain-dead MSVC warning. It
> complains about the truncation of a 64-bit constant to a 32-bit value
> when size_t is 32-bits wide, but *only with static_cast*!!! The exact
> signal that should *silence* such a warning, and in fact does silence it
> with both GCC and Clang.
>
> Anyways, this was causing grief for all the MSVC builds, so pointless
> change made. Thanks to Nikola on IRC for confirming that this works.
>
I think this warrants a comment, or someone will change it back to the 
C++ cast.

Sebastian



More information about the llvm-commits mailing list