From 0518453e2e35a7687da07b7ebb4aa5a402183811 Mon Sep 17 00:00:00 2001 From: Joey Gouly Date: Tue, 31 Dec 2013 19:15:42 +0000 Subject: [PATCH] The return value of createInternalFiles is unused, so remove it. llvm-svn: 198266 --- lld/include/lld/Core/LinkingContext.h | 2 +- lld/lib/Core/LinkingContext.cpp | 3 +-- lld/lib/ReaderWriter/ELF/Hexagon/HexagonLinkingContext.cpp | 3 +-- lld/lib/ReaderWriter/ELF/Hexagon/HexagonLinkingContext.h | 2 +- lld/lib/ReaderWriter/ELF/X86_64/X86_64LinkingContext.cpp | 3 +-- lld/lib/ReaderWriter/ELF/X86_64/X86_64LinkingContext.h | 2 +- 6 files changed, 6 insertions(+), 9 deletions(-) diff --git a/lld/include/lld/Core/LinkingContext.h b/lld/include/lld/Core/LinkingContext.h index 2b40bbadaf9b..3d7c45ec0fe5 100644 --- a/lld/include/lld/Core/LinkingContext.h +++ b/lld/include/lld/Core/LinkingContext.h @@ -236,7 +236,7 @@ public: /// during link. Flavors can override this function in their LinkingContext /// to add more internal files. These internal files are positioned before /// the actual input files. - virtual bool createInternalFiles(std::vector > &) const; + virtual void createInternalFiles(std::vector > &) const; /// Return the list of undefined symbols that are specified in the /// linker command line, using the -u option. diff --git a/lld/lib/Core/LinkingContext.cpp b/lld/lib/Core/LinkingContext.cpp index 8ac6f591253a..8a1ef257df15 100644 --- a/lld/lib/Core/LinkingContext.cpp +++ b/lld/lib/Core/LinkingContext.cpp @@ -71,7 +71,7 @@ LinkingContext::createUndefinedSymbolFile(StringRef filename) const { return std::move(undefinedSymFile); } -bool LinkingContext::createInternalFiles( +void LinkingContext::createInternalFiles( std::vector > &result) const { std::unique_ptr internalFile; internalFile = createEntrySymbolFile(); @@ -80,7 +80,6 @@ bool LinkingContext::createInternalFiles( internalFile = createUndefinedSymbolFile(); if (internalFile) result.push_back(std::move(internalFile)); - return true; } void LinkingContext::setResolverState(uint32_t state) { diff --git a/lld/lib/ReaderWriter/ELF/Hexagon/HexagonLinkingContext.cpp b/lld/lib/ReaderWriter/ELF/Hexagon/HexagonLinkingContext.cpp index 6fb956fcba7e..9f539a8da874 100644 --- a/lld/lib/ReaderWriter/ELF/Hexagon/HexagonLinkingContext.cpp +++ b/lld/lib/ReaderWriter/ELF/Hexagon/HexagonLinkingContext.cpp @@ -90,7 +90,7 @@ private: }; } -bool elf::HexagonLinkingContext::createInternalFiles( +void elf::HexagonLinkingContext::createInternalFiles( std::vector > &result) const { ELFLinkingContext::createInternalFiles(result); std::unique_ptr initFiniFile( @@ -100,5 +100,4 @@ bool elf::HexagonLinkingContext::createInternalFiles( for (auto ai:finiFunctions()) initFiniFile->addFiniFunction(ai); result.push_back(std::move(initFiniFile)); - return true; } diff --git a/lld/lib/ReaderWriter/ELF/Hexagon/HexagonLinkingContext.h b/lld/lib/ReaderWriter/ELF/Hexagon/HexagonLinkingContext.h index 534df6ceaeae..c2bf5fea1e90 100644 --- a/lld/lib/ReaderWriter/ELF/Hexagon/HexagonLinkingContext.h +++ b/lld/lib/ReaderWriter/ELF/Hexagon/HexagonLinkingContext.h @@ -66,7 +66,7 @@ public: } /// \brief Create Internal files for Init/Fini - bool createInternalFiles(std::vector > &result) const; + void createInternalFiles(std::vector > &result) const; }; } // elf diff --git a/lld/lib/ReaderWriter/ELF/X86_64/X86_64LinkingContext.cpp b/lld/lib/ReaderWriter/ELF/X86_64/X86_64LinkingContext.cpp index 69e7924c4477..48c2fca7a73a 100644 --- a/lld/lib/ReaderWriter/ELF/X86_64/X86_64LinkingContext.cpp +++ b/lld/lib/ReaderWriter/ELF/X86_64/X86_64LinkingContext.cpp @@ -101,7 +101,7 @@ void elf::X86_64LinkingContext::addPasses(PassManager &pm) { ELFLinkingContext::addPasses(pm); } -bool elf::X86_64LinkingContext::createInternalFiles( +void elf::X86_64LinkingContext::createInternalFiles( std::vector > &result) const { ELFLinkingContext::createInternalFiles(result); std::unique_ptr initFiniFile( @@ -111,6 +111,5 @@ bool elf::X86_64LinkingContext::createInternalFiles( for (auto ai:finiFunctions()) initFiniFile->addFiniFunction(ai); result.push_back(std::move(initFiniFile)); - return true; } diff --git a/lld/lib/ReaderWriter/ELF/X86_64/X86_64LinkingContext.h b/lld/lib/ReaderWriter/ELF/X86_64/X86_64LinkingContext.h index f42a627d116d..1f95c2142f7a 100644 --- a/lld/lib/ReaderWriter/ELF/X86_64/X86_64LinkingContext.h +++ b/lld/lib/ReaderWriter/ELF/X86_64/X86_64LinkingContext.h @@ -86,7 +86,7 @@ public: } /// \brief Create Internal files for Init/Fini - bool createInternalFiles(std::vector > &) const; + void createInternalFiles(std::vector > &) const; }; } // end namespace elf