llvmorg-github-actions[bot] wrote:

<!--LLVM PR SUMMARY COMMENT-->

@llvm/pr-subscribers-clang

Author: Hendrik Hübner  (HendrikHuebner)

<details>
<summary>Changes</summary>

PtrTy -&gt; VoidTy

---
Full diff: https://github.com/llvm/llvm-project/pull/214496.diff


2 Files Affected:

- (modified) clang/lib/CodeGen/CGObjCGNU.cpp (+2-2) 
- (modified) clang/test/CodeGenObjC/exceptions-personality.m (+3-1) 


``````````diff
diff --git a/clang/lib/CodeGen/CGObjCGNU.cpp b/clang/lib/CodeGen/CGObjCGNU.cpp
index 9742b496cbf5a..32a1afe310629 100644
--- a/clang/lib/CodeGen/CGObjCGNU.cpp
+++ b/clang/lib/CodeGen/CGObjCGNU.cpp
@@ -849,8 +849,8 @@ class CGObjCGNUstep : public CGObjCGNU {
         EnterCatchFn.init(&CGM, "__cxa_begin_catch", PtrTy, PtrTy);
         // void __cxa_end_catch(void)
         ExitCatchFn.init(&CGM, "__cxa_end_catch", VoidTy);
-        // void objc_exception_rethrow(void*)
-        ExceptionReThrowFn.init(&CGM, "__cxa_rethrow", PtrTy);
+        // void __cxa_rethrow(void)
+        ExceptionReThrowFn.init(&CGM, "__cxa_rethrow", VoidTy);
       } else if (usesSEHExceptions) {
         // void objc_exception_rethrow(void)
         ExceptionReThrowFn.init(&CGM, "objc_exception_rethrow", VoidTy);
diff --git a/clang/test/CodeGenObjC/exceptions-personality.m 
b/clang/test/CodeGenObjC/exceptions-personality.m
index 77ca6c2baecb7..19473c0cfb7c5 100644
--- a/clang/test/CodeGenObjC/exceptions-personality.m
+++ b/clang/test/CodeGenObjC/exceptions-personality.m
@@ -35,7 +35,7 @@ void throwing(void) {
   @catch(...)
   {
     // CHECK-MINGW-OBJC2: call ptr @__cxa_begin_catch
-    // CHECK-MINGW-OBJC2: invoke ptr @__cxa_rethrow
+    // CHECK-MINGW-OBJC2: invoke void @__cxa_rethrow
     // CHECK-MINGW-OBJC2: invoke void @__cxa_end_catch
 
     // CHECK-MINGW-GCC: call void @objc_exception_throw
@@ -51,3 +51,5 @@ void throwing(void) {
     @throw;
   }
 }
+
+// CHECK-MINGW-OBJC2: declare{{.*}} void @__cxa_rethrow()

``````````

</details>


https://github.com/llvm/llvm-project/pull/214496
_______________________________________________
cfe-commits mailing list
[email protected]
https://lists.llvm.org/cgi-bin/mailman/listinfo/cfe-commits

Reply via email to