Author: Timm Baeder Date: 2025-11-26T11:41:19+01:00 New Revision: 63e4b8c64105ea429f0d35f82b8492d6526b8c54
URL: https://github.com/llvm/llvm-project/commit/63e4b8c64105ea429f0d35f82b8492d6526b8c54 DIFF: https://github.com/llvm/llvm-project/commit/63e4b8c64105ea429f0d35f82b8492d6526b8c54.diff LOG: [clang][bytecode][NFC] Remove unused Integral range functions (#169508) Added: Modified: clang/lib/AST/ByteCode/Integral.h Removed: ################################################################################ diff --git a/clang/lib/AST/ByteCode/Integral.h b/clang/lib/AST/ByteCode/Integral.h index 5bf6621874e69..e90f1a9a74e1c 100644 --- a/clang/lib/AST/ByteCode/Integral.h +++ b/clang/lib/AST/ByteCode/Integral.h @@ -217,10 +217,6 @@ template <unsigned Bits, bool Signed> class Integral final { return Integral(Value.V); } - static bool inRange(int64_t Value, unsigned NumBits) { - return CheckRange<ReprT, Min, Max>(Value); - } - static bool increment(Integral A, Integral *R) { return add(A, Integral(ReprT(1)), A.bitWidth(), R); } @@ -323,13 +319,6 @@ template <unsigned Bits, bool Signed> class Integral final { return false; } } - template <typename T, T Min, T Max> static bool CheckRange(int64_t V) { - if constexpr (std::is_signed_v<T>) { - return Min <= V && V <= Max; - } else { - return V >= 0 && static_cast<uint64_t>(V) <= Max; - } - } }; template <unsigned Bits, bool Signed> _______________________________________________ cfe-commits mailing list [email protected] https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits
