Skip to content

Commit 541d5d9

Browse files
authored
[clang][bytecode][NFC] Reject invalid FromTypes in emitBuiltinBitcast (#118274)
instead of silently accepting them and failing later.
1 parent 34d4cd8 commit 541d5d9

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

clang/lib/AST/ByteCode/Compiler.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6514,6 +6514,8 @@ bool Compiler<Emitter>::emitBuiltinBitCast(const CastExpr *E) {
65146514
return false;
65156515
if (!this->emitGetPtrLocal(TempOffset, E))
65166516
return false;
6517+
} else {
6518+
return false;
65176519
}
65186520

65196521
if (!ToT || ToT == PT_Ptr) {

0 commit comments

Comments
 (0)