https://github.com/tbaederr created https://github.com/llvm/llvm-project/pull/118274
instead of silently accepting them and failing later. >From 989573d4b67760096a40edfae42f853a55f893fa Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Timm=20B=C3=A4der?= <tbae...@redhat.com> Date: Mon, 2 Dec 2024 10:36:58 +0100 Subject: [PATCH] [clang][bytecode][NFC] Reject invalid FromTypes in emitBuiltinBitcast instead of silently accepting them and failing later. --- clang/lib/AST/ByteCode/Compiler.cpp | 2 ++ 1 file changed, 2 insertions(+) diff --git a/clang/lib/AST/ByteCode/Compiler.cpp b/clang/lib/AST/ByteCode/Compiler.cpp index f4cc284dfb6abf..78e76ff01b0f3e 100644 --- a/clang/lib/AST/ByteCode/Compiler.cpp +++ b/clang/lib/AST/ByteCode/Compiler.cpp @@ -6514,6 +6514,8 @@ bool Compiler<Emitter>::emitBuiltinBitCast(const CastExpr *E) { return false; if (!this->emitGetPtrLocal(TempOffset, E)) return false; + } else { + return false; } if (!ToT || ToT == PT_Ptr) { _______________________________________________ cfe-commits mailing list cfe-commits@lists.llvm.org https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits