Skip to content

Commit

Permalink
Add missing parens in assert.
Browse files Browse the repository at this point in the history
Summary: Add missing parens in assert, which warn in GCC.

Subscribers: llvm-commits

Differential Revision: https://reviews.llvm.org/D27448

llvm-svn: 288792
  • Loading branch information
sam-mccall committed Dec 6, 2016
1 parent 47a42d5 commit 03435f5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion llvm/lib/CodeGen/GlobalISel/MachineIRBuilder.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -169,7 +169,7 @@ MachineInstrBuilder MachineIRBuilder::buildConstant(unsigned Res,
const ConstantInt &Val) {
LLT Ty = MRI->getType(Res);

assert(Ty.isScalar() || Ty.isPointer() && "invalid operand type");
assert((Ty.isScalar() || Ty.isPointer()) && "invalid operand type");

const ConstantInt *NewVal = &Val;
if (Ty.getSizeInBits() != Val.getBitWidth())
Expand Down

0 comments on commit 03435f5

Please sign in to comment.