diff options
| author | Adrian Prantl <aprantl@apple.com> | 2014-01-07 22:05:45 +0000 |
|---|---|---|
| committer | Adrian Prantl <aprantl@apple.com> | 2014-01-07 22:05:45 +0000 |
| commit | b9b5b2ce07cfddd64e7e2cd06353cc9f4a566ede (patch) | |
| tree | 4a1254070d1abbe4b3f271b8b7010371b96e23b9 /lib/CodeGen/CGDebugInfo.cpp | |
| parent | d758e0751730d21aecab91a32999157aa31cff50 (diff) | |
| download | clang-b9b5b2ce07cfddd64e7e2cd06353cc9f4a566ede.tar.gz clang-b9b5b2ce07cfddd64e7e2cd06353cc9f4a566ede.tar.bz2 clang-b9b5b2ce07cfddd64e7e2cd06353cc9f4a566ede.tar.xz | |
Revert "Debug info: Implement a cleaner version of r198461. For symmetry with"
This reverts commit 198699 so we can get a cleaner patch.
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@198713 91177308-0d34-0410-b5e6-96231b3b80d8
Diffstat (limited to 'lib/CodeGen/CGDebugInfo.cpp')
| -rw-r--r-- | lib/CodeGen/CGDebugInfo.cpp | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/CodeGen/CGDebugInfo.cpp b/lib/CodeGen/CGDebugInfo.cpp index 2977ed2223..3138d82fb8 100644 --- a/lib/CodeGen/CGDebugInfo.cpp +++ b/lib/CodeGen/CGDebugInfo.cpp @@ -2537,7 +2537,8 @@ void CGDebugInfo::EmitFunctionStart(GlobalDecl GD, QualType FnType, /// information in the source file. If the location is invalid, the /// previous location will be reused. void CGDebugInfo::EmitLocation(CGBuilderTy &Builder, SourceLocation Loc, - bool ForceColumnInfo) { + bool ForceColumnInfo, + llvm::MDNode *ForceScope) { // Update our current location setLocation(Loc); @@ -2556,7 +2557,7 @@ void CGDebugInfo::EmitLocation(CGBuilderTy &Builder, SourceLocation Loc, // Update last state. PrevLoc = CurLoc; - llvm::MDNode *Scope = LexicalBlockStack.back(); + llvm::MDNode *Scope = ForceScope ? ForceScope : &*LexicalBlockStack.back(); Builder.SetCurrentDebugLocation(llvm::DebugLoc::get (getLineNumber(CurLoc), getColumnNumber(CurLoc, ForceColumnInfo), |
