Skip to content

Commit b169200

Browse files
mmhaDhruvSrivastavaX
authored andcommitted
[CIR] Fix missing return value warning in maybePromoteBoolResult (llvm#142673)
This is NFC and simply adds an llvm_unreachable
1 parent 2b8201f commit b169200

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

clang/lib/CIR/CodeGen/CIRGenExprScalar.cpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -104,6 +104,7 @@ class ScalarExprEmitter : public StmtVisitor<ScalarExprEmitter, mlir::Value> {
104104
return builder.createBoolToInt(value, dstTy);
105105
if (mlir::isa<cir::BoolType>(dstTy))
106106
return value;
107+
llvm_unreachable("Can only promote integer or boolean types");
107108
}
108109

109110
//===--------------------------------------------------------------------===//

0 commit comments

Comments
 (0)