diff options
| author | Benjamin Kramer <benny.kra@googlemail.com> | 2013-08-25 22:46:27 +0000 |
|---|---|---|
| committer | Benjamin Kramer <benny.kra@googlemail.com> | 2013-08-25 22:46:27 +0000 |
| commit | 9581ed07dee5376002620a0cfb363c6b9e5bdd3e (patch) | |
| tree | c857394e65c42b3fdd7926f9bc31461f0049d4ae /lib/CodeGen/CodeGenFunction.h | |
| parent | 5db8b3138f36e11bca835881e81cc56bbd7b4fa4 (diff) | |
| download | clang-9581ed07dee5376002620a0cfb363c6b9e5bdd3e.tar.gz clang-9581ed07dee5376002620a0cfb363c6b9e5bdd3e.tar.bz2 clang-9581ed07dee5376002620a0cfb363c6b9e5bdd3e.tar.xz | |
CodeGen: Unify two implementations of canDevirtualizeMemberFunctionCall.
They were mostly copy&paste of each other, move it to CodeGenFunction. Of course
the two implementations have diverged over time; the one in CGExprCXX seems to
be the more modern one so I picked that one and moved it to CGClass which feels
like a better home for it. No intended functionality change.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@189203 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/CodeGenFunction.h')
| -rw-r--r-- | lib/CodeGen/CodeGenFunction.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/lib/CodeGen/CodeGenFunction.h b/lib/CodeGen/CodeGenFunction.h index f8dcfa3004..ff7b700433 100644 --- a/lib/CodeGen/CodeGenFunction.h +++ b/lib/CodeGen/CodeGenFunction.h @@ -1196,6 +1196,12 @@ public: /// to by This. llvm::Value *GetVTablePtr(llvm::Value *This, llvm::Type *Ty); + + /// CanDevirtualizeMemberFunctionCalls - Checks whether virtual calls on given + /// expr can be devirtualized. + bool CanDevirtualizeMemberFunctionCall(const Expr *Base, + const CXXMethodDecl *MD); + /// EnterDtorCleanups - Enter the cleanups necessary to complete the /// given phase of destruction for a destructor. The end result /// should call destructors on members and base classes in reverse |
