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 | c8be95274d615a6ca3d4b717267100531ff84ed2 (patch) | |
tree | 16207c834f17e11f4a46d55c7a35958bc7102140 /clang/lib/CodeGen/CGDebugInfo.cpp | |
parent | a25ee78fc0afc78dd363037daef4245f92e23218 (diff) | |
download | bcm5719-llvm-c8be95274d615a6ca3d4b717267100531ff84ed2.tar.gz bcm5719-llvm-c8be95274d615a6ca3d4b717267100531ff84ed2.zip |
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.
llvm-svn: 103025
Diffstat (limited to 'clang/lib/CodeGen/CGDebugInfo.cpp')
-rw-r--r-- | clang/lib/CodeGen/CGDebugInfo.cpp | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/clang/lib/CodeGen/CGDebugInfo.cpp b/clang/lib/CodeGen/CGDebugInfo.cpp index 4963e73fe46..48ae5113b3a 100644 --- a/clang/lib/CodeGen/CGDebugInfo.cpp +++ b/clang/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()) |