diff options
author | David Blaikie <dblaikie@gmail.com> | 2013-01-05 20:03:07 +0000 |
---|---|---|
committer | David Blaikie <dblaikie@gmail.com> | 2013-01-05 20:03:07 +0000 |
commit | 219c7d9f6491c4963e62c1d21d3e45713fbfea0c (patch) | |
tree | f8ca36ff35ab3d972b58652a192bc51babf8f6d6 /clang/lib/CodeGen/CGDebugInfo.cpp | |
parent | a234c65613a92357d8cf963444d35a51885d93ad (diff) | |
download | bcm5719-llvm-219c7d9f6491c4963e62c1d21d3e45713fbfea0c.tar.gz bcm5719-llvm-219c7d9f6491c4963e62c1d21d3e45713fbfea0c.zip |
PR14573: Unnamed parameters in debug info, Part 2
Catch some cases I'd missed in r171605 related to unnamed parameters of record
type. This resolves all remaining cases of PR14573 suppression in the GDB 7.5
test suite. Fix to the test suite to follow.
llvm-svn: 171633
Diffstat (limited to 'clang/lib/CodeGen/CGDebugInfo.cpp')
-rw-r--r-- | clang/lib/CodeGen/CGDebugInfo.cpp | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/clang/lib/CodeGen/CGDebugInfo.cpp b/clang/lib/CodeGen/CGDebugInfo.cpp index 1ec9464e8ad..bc715f4d6d2 100644 --- a/clang/lib/CodeGen/CGDebugInfo.cpp +++ b/clang/lib/CodeGen/CGDebugInfo.cpp @@ -2432,7 +2432,7 @@ void CGDebugInfo::EmitDeclare(const VarDecl *VD, unsigned Tag, // If VD is an anonymous union then Storage represents value for // all union fields. const RecordDecl *RD = cast<RecordDecl>(RT->getDecl()); - if (RD->isUnion()) { + if (RD->isUnion() && RD->isAnonymousStructOrUnion()) { for (RecordDecl::field_iterator I = RD->field_begin(), E = RD->field_end(); I != E; ++I) { @@ -2456,8 +2456,8 @@ void CGDebugInfo::EmitDeclare(const VarDecl *VD, unsigned Tag, DBuilder.insertDeclare(Storage, D, Builder.GetInsertBlock()); Call->setDebugLoc(llvm::DebugLoc::get(Line, Column, Scope)); } + return; } - return; } // Create the descriptor for the variable. |