On 01/12/2020 12:40, Frederik Seiffert wrote:
Am 30.11.2020 um 17:59 schrieb David Chisnall <gnus...@theravensnest.org>:

I think this is a clang bug.  I am probably guarding this on an MSVC target 
triple and not on SEH exceptions.  Please can you file a clang bug and assign 
it to me?


https://bugs.llvm.org/show_bug.cgi?id=48348

I hope I summarized this somewhat correctly. Happy to try to build Clang from 
source once there is a patch.

I know it might not be your say, but if there is any way to still get this into 
a Clang 11 point release that would be very much appreciated. If there’s 
anything I can do to help make that happen please just let me know.

Please can you try the attached patch?

Thanks,

David

diff --git a/clang/lib/CodeGen/CGObjCGNU.cpp b/clang/lib/CodeGen/CGObjCGNU.cpp
index 9825d7bca18c..102da37a99e2 100644
--- a/clang/lib/CodeGen/CGObjCGNU.cpp
+++ b/clang/lib/CodeGen/CGObjCGNU.cpp
@@ -2134,8 +2134,7 @@ CGObjCGNU::CGObjCGNU(CodeGenModule &cgm, unsigned runtimeABIVersion,
     ProtocolVersion(protocolClassVersion), ClassABIVersion(classABI) {

   msgSendMDKind = VMContext.getMDKindID("GNUObjCMessageSend");
-  usesSEHExceptions =
- cgm.getContext().getTargetInfo().getTriple().isWindowsMSVCEnvironment();
+  usesSEHExceptions = cgm.getLangOpts().SEHExceptions;

   CodeGenTypes &Types = CGM.getTypes();
   IntTy = cast<llvm::IntegerType>(

Reply via email to