summaryrefslogtreecommitdiffstats
path: root/llvm/lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp
diff options
context:
space:
mode:
authorAdrian Prantl <aprantl@apple.com>2013-11-15 23:21:39 +0000
committerAdrian Prantl <aprantl@apple.com>2013-11-15 23:21:39 +0000
commit4583f7d51ac8ec72ebc4955fe3e0279f9b1a0a08 (patch)
treebca573c42b5aa0b887133523392c13300a5db037 /llvm/lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp
parent56045cb219a8856677f179a52c1cb6ea73360271 (diff)
downloadbcm5719-llvm-4583f7d51ac8ec72ebc4955fe3e0279f9b1a0a08.tar.gz
bcm5719-llvm-4583f7d51ac8ec72ebc4955fe3e0279f9b1a0a08.zip
Replace the dangling context hotfix with an assertion.
llvm-svn: 194883
Diffstat (limited to 'llvm/lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp')
-rw-r--r--llvm/lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp5
1 files changed, 1 insertions, 4 deletions
diff --git a/llvm/lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp b/llvm/lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp
index 508a6927c20..a47eeab430c 100644
--- a/llvm/lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp
+++ b/llvm/lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp
@@ -886,10 +886,7 @@ DIE *CompileUnit::getOrCreateTypeDIE(const MDNode *TyNode) {
// Construct the context before querying for the existence of the DIE in case
// such construction creates the DIE.
DIE *ContextDIE = getOrCreateContextDIE(resolve(Ty.getContext()));
- // TODO: Investigate if this beavior is intentional and possibly
- // replace it with an assert.
- if (!ContextDIE)
- ContextDIE = getCUDie();
+ assert(ContextDIE);
DIE *TyDIE = getDIE(Ty);
if (TyDIE)
OpenPOWER on IntegriCloud