Make sure to emit the catch parameter as well as the catch body.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@56101 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/lib/CodeGen/CGObjC.cpp b/lib/CodeGen/CGObjC.cpp
index a3da594..73f9489 100644
--- a/lib/CodeGen/CGObjC.cpp
+++ b/lib/CodeGen/CGObjC.cpp
@@ -456,4 +456,12 @@
CGM.getObjCRuntime().EmitThrowStmt(*this, S);
}
+void CodeGenFunction::EmitObjCAtCatchStmt(const ObjCAtCatchStmt &S)
+{
+ if (const Stmt *CatchParam = S.getCatchParamStmt())
+ EmitStmt(CatchParam);
+
+ EmitStmt(S.getCatchBody());
+}
+
CGObjCRuntime::~CGObjCRuntime() {}