A new clang warning introduced in r367497 was complaining about
the change in value.
Details
Details
Diff Detail
Diff Detail
- Repository
- rG LLVM Github Monorepo
Event Timeline
Comment Actions
This patch is intended to address new warnings like the one below that shows up with clang on a hexagon target:
libcxx/include/random:3650:40: error: implicit conversion from 'unsigned long' to 'float' changes value from 2147483645 to 2147483648 [-Werror,-Wimplicit-int-float-conversion] const _RealType _Rp = _URNG::max() - _URNG::min() + _RealType(1); ~~~~~~~~~~~~~^~~~~~~~~~~~~~ ~
I *think* the behavior is intended/expected, so that's why I include explicit casts here to avoid the implicit conversion warning.
The test case has corresponding warnings and I think I'll just include those in this commit here.
Comment Actions
This looks right to me (and after a short discussion with Marshall it seemed alright to him too). I'm going to check it in to fix the several builders that are broken right now.