[lld] r277600 - Revert an unintentional change from r277599
Nico Weber via llvm-commits
llvm-commits at lists.llvm.org
Wed Aug 3 07:38:53 PDT 2016
Author: nico
Date: Wed Aug 3 09:38:52 2016
New Revision: 277600
URL: http://llvm.org/viewvc/llvm-project?rev=277600&view=rev
Log:
Revert an unintentional change from r277599
Modified:
lld/trunk/COFF/InputFiles.cpp
Modified: lld/trunk/COFF/InputFiles.cpp
URL: http://llvm.org/viewvc/llvm-project/lld/trunk/COFF/InputFiles.cpp?rev=277600&r1=277599&r2=277600&view=diff
==============================================================================
--- lld/trunk/COFF/InputFiles.cpp (original)
+++ lld/trunk/COFF/InputFiles.cpp Wed Aug 3 09:38:52 2016
@@ -64,7 +64,7 @@ std::string InputFile::getShortName() {
void ArchiveFile::parse() {
// Parse a MemoryBufferRef as an archive file.
- File = check(Archive::create(MB), getShortName());
+ File = check(Archive::create(MB), "failed to parse static library");
// Allocate a buffer for Lazy objects.
size_t NumSyms = File->getNumberOfSymbols();
@@ -81,7 +81,7 @@ void ArchiveFile::parse() {
for (auto &Child : File->children(Err))
Seen[Child.getChildOffset()].clear();
if (Err)
- fatal(Err, getShortName());
+ fatal(Err, "failed to parse static library");
}
// Returns a buffer pointing to a member file containing a given symbol.
@@ -109,13 +109,13 @@ MemoryBufferRef ArchiveFile::getMember(c
void ObjectFile::parse() {
// Parse a memory buffer as a COFF file.
std::unique_ptr<Binary> Bin =
- check(createBinary(MB), getShortName());
+ check(createBinary(MB), "failed to parse object file");
if (auto *Obj = dyn_cast<COFFObjectFile>(Bin.get())) {
Bin.release();
COFFObj.reset(Obj);
} else {
- fatal(getShortName() + " is not a COFF file");
+ fatal(getName() + " is not a COFF file");
}
// Read section and symbol tables.
@@ -169,7 +169,7 @@ void ObjectFile::initializeSymbols() {
for (uint32_t I = 0; I < NumSymbols; ++I) {
// Get a COFFSymbolRef object.
COFFSymbolRef Sym =
- check(COFFObj->getSymbol(I), "broken object file: " + getShortName());
+ check(COFFObj->getSymbol(I), "broken object file: " + getName());
const void *AuxP = nullptr;
if (Sym.getNumberOfAuxSymbols())
@@ -231,12 +231,12 @@ Defined *ObjectFile::createDefined(COFFS
// Reserved sections numbers don't have contents.
if (llvm::COFF::isReservedSectionNumber(SectionNumber))
- fatal("broken object file: " + getShortName());
+ fatal("broken object file: " + getName());
// This symbol references a section which is not present in the section
// header.
if ((uint32_t)SectionNumber >= SparseChunks.size())
- fatal("broken object file: " + getShortName());
+ fatal("broken object file: " + getName());
// Nothing else to do without a section chunk.
auto *SC = cast_or_null<SectionChunk>(SparseChunks[SectionNumber]);
More information about the llvm-commits
mailing list