Skip to content

Commit 85ccb4e

Browse files
committed
reinserted assert for lowBits in APInt::SetBits
1 parent b1749f1 commit 85ccb4e

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

llvm/include/llvm/ADT/APInt.h

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1366,6 +1366,7 @@ class [[nodiscard]] APInt {
13661366
/// This function handles case when \p loBit <= \p hiBit.
13671367
void setBits(unsigned loBit, unsigned hiBit) {
13681368
assert(hiBit <= BitWidth && "hiBit out of range");
1369+
assert(loBit <= BitWidth && "loBit out of range");
13691370
assert(loBit <= hiBit && "loBit greater than hiBit");
13701371
if (loBit == hiBit)
13711372
return;

0 commit comments

Comments
 (0)