diff --git a/llvm/unittests/DebugInfo/DWARF/DWARFDebugLineTest.cpp b/llvm/unittests/DebugInfo/DWARF/DWARFDebugLineTest.cpp --- a/llvm/unittests/DebugInfo/DWARF/DWARFDebugLineTest.cpp +++ b/llvm/unittests/DebugInfo/DWARF/DWARFDebugLineTest.cpp @@ -114,8 +114,8 @@ checkError(ArrayRef{ExpectedMsg}, std::move(Err)); } - void checkGetOrParseLineTableEmitsError(StringRef ExpectedMsg, - uint64_t Offset = 0) { + void checkGetOrParseLineTableEmitsFatalError(StringRef ExpectedMsg, + uint64_t Offset = 0) { auto ExpectedLineTable = Line.getOrParseLineTable( LineData, Offset, *Context, nullptr, RecordRecoverable); EXPECT_FALSE(ExpectedLineTable); @@ -124,8 +124,8 @@ checkError(ExpectedMsg, ExpectedLineTable.takeError()); } - void checkGetOrParseLineTableEmitsError(ArrayRef ExpectedMsgs, - uint64_t Offset = 0) { + void checkGetOrParseLineTableEmitsFatalError(ArrayRef ExpectedMsgs, + uint64_t Offset = 0) { auto ExpectedLineTable = Line.getOrParseLineTable( LineData, Offset, *Context, nullptr, RecordRecoverable); EXPECT_FALSE(ExpectedLineTable); @@ -212,13 +212,13 @@ return; generate(); - checkGetOrParseLineTableEmitsError( + checkGetOrParseLineTableEmitsFatalError( "offset 0x00000000 is not a valid debug line section offset", 0); // Repeat to show that an error is reported each time. - checkGetOrParseLineTableEmitsError( + checkGetOrParseLineTableEmitsFatalError( "offset 0x00000000 is not a valid debug line section offset", 0); // Show that an error is reported for later offsets too. - checkGetOrParseLineTableEmitsError( + checkGetOrParseLineTableEmitsFatalError( "offset 0x00000001 is not a valid debug line section offset", 1); } @@ -231,7 +231,7 @@ generate(); - checkGetOrParseLineTableEmitsError( + checkGetOrParseLineTableEmitsFatalError( "offset 0x00000001 is not a valid debug line section offset", 1); } @@ -310,7 +310,7 @@ generate(); - checkGetOrParseLineTableEmitsError( + checkGetOrParseLineTableEmitsFatalError( "parsing line table prologue at offset 0x00000000 unsupported reserved " "unit length found of value 0xfffffff0"); } @@ -325,9 +325,10 @@ generate(); - checkGetOrParseLineTableEmitsError("parsing line table prologue at offset " - "0x00000000 found unsupported version " - "0x01"); + checkGetOrParseLineTableEmitsFatalError( + "parsing line table prologue at offset " + "0x00000000 found unsupported version " + "0x01"); } TEST_F(DebugLineBasicFixture, ErrorForInvalidV5IncludeDirTable) { @@ -358,7 +359,7 @@ generate(); - checkGetOrParseLineTableEmitsError( + checkGetOrParseLineTableEmitsFatalError( {"parsing line table prologue at 0x00000000 found an invalid directory " "or file table description at 0x00000014", "failed to parse entry content descriptions because no path was found"}); @@ -380,7 +381,7 @@ uint64_t ExpectedEnd = Prologue.TotalLength + 1 + Prologue.sizeofTotalLength(); - checkGetOrParseLineTableEmitsError( + checkGetOrParseLineTableEmitsFatalError( (Twine("parsing line table prologue at 0x00000000 should have ended at " "0x000000") + Twine::utohexstr(ExpectedEnd) + " but it ended at 0x000000" + @@ -411,7 +412,7 @@ Prologue.TotalLength - 1 + Prologue.sizeofTotalLength(); if (Version < 5) --ExpectedEnd; - checkGetOrParseLineTableEmitsError( + checkGetOrParseLineTableEmitsFatalError( (Twine("parsing line table prologue at 0x00000000 should have ended at " "0x000000") + Twine::utohexstr(ExpectedEnd) + " but it ended at 0x000000" +