Simplify code and make it more uniform.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@14077
91177308-0d34-0410-b5e6-
96231b3b80d8
inline bool isConditional() const { return Operands.size() == 3; }
inline Value *getCondition() const {
- return isUnconditional() ? 0 : reinterpret_cast<Value*>(Operands[2].get());
+ assert(isConditional() && "Cannot get condition of an uncond branch!");
+ return Operands[2].get();
}
void setCondition(Value *V) {