aboutsummaryrefslogtreecommitdiff
path: root/lib/Bitcode
diff options
context:
space:
mode:
authorBill Wendling <isanbard@gmail.com>2011-07-28 21:14:13 +0000
committerBill Wendling <isanbard@gmail.com>2011-07-28 21:14:13 +0000
commit7379b6650008fba555d5472d5c76e8efc59e8a21 (patch)
tree7d817da4daae05b68a4da09bb3927cd7d8407702 /lib/Bitcode
parent6bd4842f89ef0f6a53b78664f9f3f2a1006117a9 (diff)
The personality function should be a Function* and not just a Value*.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@136392 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/Bitcode')
-rw-r--r--lib/Bitcode/Reader/BitcodeReader.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/lib/Bitcode/Reader/BitcodeReader.cpp b/lib/Bitcode/Reader/BitcodeReader.cpp
index 4b83958e78..bab33ed257 100644
--- a/lib/Bitcode/Reader/BitcodeReader.cpp
+++ b/lib/Bitcode/Reader/BitcodeReader.cpp
@@ -2539,7 +2539,8 @@ bool BitcodeReader::ParseFunctionBody(Function *F) {
bool IsCleanup = !!Record[Idx++];
unsigned NumClauses = Record[Idx++];
- LandingPadInst *LP = LandingPadInst::Create(Ty, PersFn, NumClauses);
+ LandingPadInst *LP = LandingPadInst::Create(Ty, cast<Function>(PersFn),
+ NumClauses);
LP->setCleanup(IsCleanup);
for (unsigned J = 0; J != NumClauses; ++J) {
LandingPadInst::ClauseType CT =