Skip to content

Commit 23835f0

Browse files
author
einvbri
committed
Really address the review comments I missed the first time
:)
1 parent e145662 commit 23835f0

File tree

1 file changed

+1
-6
lines changed
  • clang/include/clang/StaticAnalyzer/Core/PathSensitive

1 file changed

+1
-6
lines changed

clang/include/clang/StaticAnalyzer/Core/PathSensitive/SMTConv.h

Lines changed: 1 addition & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -584,10 +584,6 @@ class SMTConv {
584584
return Ty;
585585
}
586586

587-
// static inline bool IsPower2(unsigned bits) {
588-
// return bits > 0 && (bits & (bits - 1)) == 0;
589-
// }
590-
591587
// Get the QualTy for the input APSInt, and fix it if it has a bitwidth of 1.
592588
static inline std::pair<llvm::APSInt, QualType>
593589
fixAPSInt(ASTContext &Ctx, const llvm::APSInt &Int) {
@@ -601,8 +597,7 @@ class SMTConv {
601597
if (APSIntBitwidth == 1 && Ty.isNull()) {
602598
NewInt = Int.extend(Ctx.getTypeSize(Ctx.BoolTy));
603599
Ty = getAPSIntType(Ctx, NewInt);
604-
} else if (!llvm::isPowerOf2_32(APSIntBitwidth) &&
605-
!getAPSIntType(Ctx, Int).isNull()) {
600+
} else if (!llvm::isPowerOf2_32(APSIntBitwidth) && !Ty.isNull()) {
606601
NewInt = Int.extend(Ctx.getTypeSize(Ty));
607602
} else
608603
NewInt = Int;

0 commit comments

Comments
 (0)