diff options
author | Douglas Gregor <dgregor@apple.com> | 2010-05-04 18:18:31 +0000 |
---|---|---|
committer | Douglas Gregor <dgregor@apple.com> | 2010-05-04 18:18:31 +0000 |
commit | 5f970eee81372dfc6a1457c3d6d052af04e32a38 (patch) | |
tree | 8f43d6ca1f72dd9f7b6a59c8041060f148984687 /lib/CodeGen/CGDebugInfo.cpp | |
parent | d33ded52b06f7be00b95c1ce546924b4468adf9a (diff) |
When instantiating a function that was declared via a typedef, e.g.,
typedef int functype(int, int);
functype func;
also instantiate the synthesized function parameters for the resulting
function declaration.
With this change, Boost.Wave builds and passes all of its regression
tests.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@103025 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/CGDebugInfo.cpp')
-rw-r--r-- | lib/CodeGen/CGDebugInfo.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/lib/CodeGen/CGDebugInfo.cpp b/lib/CodeGen/CGDebugInfo.cpp index 4963e73fe4..48ae5113b3 100644 --- a/lib/CodeGen/CGDebugInfo.cpp +++ b/lib/CodeGen/CGDebugInfo.cpp @@ -495,7 +495,10 @@ CollectRecordFields(const RecordDecl *RD, llvm::DIFile Unit, llvm::DIType CGDebugInfo::getOrCreateMethodType(const CXXMethodDecl *Method, llvm::DIFile Unit) { - llvm::DIType FnTy = getOrCreateType(Method->getType(), Unit); + llvm::DIType FnTy + = getOrCreateType(QualType(Method->getType()->getAs<FunctionProtoType>(), + 0), + Unit); // Static methods do not need "this" pointer argument. if (Method->isStatic()) |