[llvm] [ADT] [NFC] Resolve a potential overload ambiguity in the ADT unit tests (PR #85341)
Simon Pilgrim via llvm-commits
llvm-commits at lists.llvm.org
Fri Mar 15 02:49:42 PDT 2024
================
@@ -2918,7 +2918,7 @@ TEST(APIntTest, Average) {
APInt A100(32, 100);
APInt A101(32, 101);
APInt A200(32, 200, false);
- APInt ApUMax(32, UINT_MAX, false);
+ APInt ApUMax(32, static_cast<uint64_t>(UINT_MAX), false);
----------------
RKSimon wrote:
This would be my preferred option:
```cpp
APInt ApUMax = APInt::getMaxValue(32);
```
https://github.com/llvm/llvm-project/pull/85341
More information about the llvm-commits
mailing list