From aedaa723c26c33d4f9497a79d9d74a3c197fa262 Mon Sep 17 00:00:00 2001 From: David Blaikie Date: Fri, 15 Nov 2013 23:50:53 +0000 Subject: [PATCH] DwarfCompileUnit: Simplify getLanguage() calls to use existing member function git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@194892 91177308-0d34-0410-b5e6-96231b3b80d8 --- lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp b/lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp index a47eeab430c..175febddf25 100644 --- a/lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp +++ b/lib/CodeGen/AsmPrinter/DwarfCompileUnit.cpp @@ -57,7 +57,7 @@ DIEEntry *CompileUnit::createDIEEntry(DIE *Entry) { /// getDefaultLowerBound - Return the default lower bound for an array. If the /// DWARF version doesn't handle the language, return -1. int64_t CompileUnit::getDefaultLowerBound() const { - switch (DICompileUnit(Node).getLanguage()) { + switch (getLanguage()) { default: break; @@ -1165,7 +1165,7 @@ void CompileUnit::constructTypeDIE(DIE &Buffer, DICompositeType CTy) { } // Add prototype flag if we're dealing with a C language and the // function has been prototyped. - uint16_t Language = DICompileUnit(Node).getLanguage(); + uint16_t Language = getLanguage(); if (isPrototyped && (Language == dwarf::DW_LANG_C89 || Language == dwarf::DW_LANG_C99 || Language == dwarf::DW_LANG_ObjC)) @@ -1423,7 +1423,7 @@ DIE *CompileUnit::getOrCreateSubprogramDIE(DISubprogram SP) { // Add the prototype if we have a prototype and we have a C like // language. - uint16_t Language = DICompileUnit(Node).getLanguage(); + uint16_t Language = getLanguage(); if (SP.isPrototyped() && (Language == dwarf::DW_LANG_C89 || Language == dwarf::DW_LANG_C99 || Language == dwarf::DW_LANG_ObjC)) -- 2.11.0