Update ExceptionDemo for exception handling API changes (personality function call...
authorDavid Blaikie <dblaikie@gmail.com>
Fri, 14 Aug 2015 00:37:16 +0000 (00:37 +0000)
committerDavid Blaikie <dblaikie@gmail.com>
Fri, 14 Aug 2015 00:37:16 +0000 (00:37 +0000)
The ExceptionDemo now compiles, but doesn't link... undefined type
references to various typeinfo.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@244997 91177308-0d34-0410-b5e6-96231b3b80d8

examples/ExceptionDemo/ExceptionDemo.cpp

index 5043a65..506f322 100644 (file)
@@ -1265,10 +1265,10 @@ static llvm::Function *createCatchWrappedInvokeFunction(
   builder.SetInsertPoint(exceptionBlock);
 
   llvm::Function *personality = module.getFunction("ourPersonality");
+  ret->setPersonalityFn(personality);
 
   llvm::LandingPadInst *caughtResult =
     builder.CreateLandingPad(ourCaughtResultType,
-                             personality,
                              numExceptionsToCatch,
                              "landingPad");