[PATCH] D59239: ELF: Simplify. NFCI.
Peter Collingbourne via Phabricator via llvm-commits
llvm-commits at lists.llvm.org
Tue Mar 12 12:18:31 PDT 2019
This revision was automatically updated to reflect the committed changes.
Closed by commit rL355954: ELF: Simplify. NFCI. (authored by pcc, committed by ).
Changed prior to commit:
https://reviews.llvm.org/D59239?vs=190201&id=190309#toc
Repository:
rL LLVM
CHANGES SINCE LAST ACTION
https://reviews.llvm.org/D59239/new/
https://reviews.llvm.org/D59239
Files:
lld/trunk/ELF/LinkerScript.cpp
Index: lld/trunk/ELF/LinkerScript.cpp
===================================================================
--- lld/trunk/ELF/LinkerScript.cpp
+++ lld/trunk/ELF/LinkerScript.cpp
@@ -636,7 +636,6 @@
// Add sections that didn't match any sections command.
void LinkerScript::addOrphanSections() {
- unsigned End = SectionCommands.size();
StringMap<OutputSection *> Map;
std::vector<OutputSection *> V;
@@ -651,8 +650,7 @@
else if (Config->OrphanHandling == OrphanHandlingPolicy::Warn)
warn(toString(S) + " is being placed in '" + Name + "'");
- if (OutputSection *Sec =
- findByName(makeArrayRef(SectionCommands).slice(0, End), Name)) {
+ if (OutputSection *Sec = findByName(SectionCommands, Name)) {
Sec->addSection(cast<InputSection>(S));
return;
}
-------------- next part --------------
A non-text attachment was scrubbed...
Name: D59239.190309.patch
Type: text/x-patch
Size: 810 bytes
Desc: not available
URL: <http://lists.llvm.org/pipermail/llvm-commits/attachments/20190312/0a24fdbf/attachment.bin>
More information about the llvm-commits
mailing list