summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorDavid Blaikie <dblaikie@gmail.com>2015-04-17 06:40:11 +0000
committerDavid Blaikie <dblaikie@gmail.com>2015-04-17 06:40:11 +0000
commite6aba2806cc3380b7c2cb29aa6ceba8af4c71534 (patch)
tree883af00dc5734bf371cf6cd926ce1d145875294b
parentede3193bbd336bd817b918b348243fc3bfc3ab6b (diff)
downloadbcm5719-llvm-e6aba2806cc3380b7c2cb29aa6ceba8af4c71534.tar.gz
bcm5719-llvm-e6aba2806cc3380b7c2cb29aa6ceba8af4c71534.zip
Narrow down the type of CallInst::getFunctionType to a FunctionType
llvm-svn: 235159
-rw-r--r--llvm/include/llvm/IR/Instructions.h5
1 files changed, 3 insertions, 2 deletions
diff --git a/llvm/include/llvm/IR/Instructions.h b/llvm/include/llvm/IR/Instructions.h
index 1f2ca301d24..ddb441b6e5d 100644
--- a/llvm/include/llvm/IR/Instructions.h
+++ b/llvm/include/llvm/IR/Instructions.h
@@ -1337,8 +1337,9 @@ public:
~CallInst() override;
- Type *getFunctionType() const {
- return cast<PointerType>(getCalledValue()->getType())->getElementType();
+ FunctionType *getFunctionType() const {
+ return cast<FunctionType>(
+ cast<PointerType>(getCalledValue()->getType())->getElementType());
}
// Note that 'musttail' implies 'tail'.
OpenPOWER on IntegriCloud