diff options
| author | David Blaikie <dblaikie@gmail.com> | 2014-06-02 16:32:05 +0000 |
|---|---|---|
| committer | David Blaikie <dblaikie@gmail.com> | 2014-06-02 16:32:05 +0000 |
| commit | f9ea242d4fd48bec2a3f244dc60460d8a4bce539 (patch) | |
| tree | c4354ab4caf0b1214457642594ee84ba367de1d4 /clang | |
| parent | 4760813831fbda6bdc7090b8e3daef229bff10f8 (diff) | |
| download | bcm5719-llvm-f9ea242d4fd48bec2a3f244dc60460d8a4bce539.tar.gz bcm5719-llvm-f9ea242d4fd48bec2a3f244dc60460d8a4bce539.zip | |
CGDebugInfo: Simplify/invert createLexicalBlock parameter construction.
llvm-svn: 210033
Diffstat (limited to 'clang')
| -rw-r--r-- | clang/lib/CodeGen/CGDebugInfo.cpp | 13 |
1 files changed, 5 insertions, 8 deletions
diff --git a/clang/lib/CodeGen/CGDebugInfo.cpp b/clang/lib/CodeGen/CGDebugInfo.cpp index e2ba70ac549..4ac1011385c 100644 --- a/clang/lib/CodeGen/CGDebugInfo.cpp +++ b/clang/lib/CodeGen/CGDebugInfo.cpp @@ -2579,14 +2579,11 @@ void CGDebugInfo::EmitLocation(CGBuilderTy &Builder, SourceLocation Loc, /// CreateLexicalBlock - Creates a new lexical block node and pushes it on /// the stack. void CGDebugInfo::CreateLexicalBlock(SourceLocation Loc) { - llvm::DIDescriptor D = - DBuilder.createLexicalBlock(LexicalBlockStack.empty() ? - llvm::DIDescriptor() : - llvm::DIDescriptor(LexicalBlockStack.back()), - getOrCreateFile(CurLoc), - getLineNumber(CurLoc), - getColumnNumber(CurLoc), - 0); + llvm::DIDescriptor D = DBuilder.createLexicalBlock( + llvm::DIDescriptor(LexicalBlockStack.empty() ? nullptr + : LexicalBlockStack.back()), + getOrCreateFile(CurLoc), getLineNumber(CurLoc), getColumnNumber(CurLoc), + 0); llvm::MDNode *DN = D; LexicalBlockStack.push_back(DN); } |

