diff options
author | Fangrui Song <maskray@google.com> | 2018-09-26 20:54:42 +0000 |
---|---|---|
committer | Fangrui Song <maskray@google.com> | 2018-09-26 20:54:42 +0000 |
commit | dbaeec6892b98454e3a736050bbd5a3ebf3cac7d (patch) | |
tree | f194f6671d98bfd7c87ce123eb8642bb25dad605 /lld/ELF/InputSection.cpp | |
parent | ed5bb932a202dd5ede1cb70a032f094b35bbd176 (diff) | |
download | bcm5719-llvm-dbaeec6892b98454e3a736050bbd5a3ebf3cac7d.tar.gz bcm5719-llvm-dbaeec6892b98454e3a736050bbd5a3ebf3cac7d.zip |
[ELF] llvm::sort(C.begin(), C.end(), ...) -> llvm::sort(C, ...)
Summary: The convenience wrapper in STLExtras is available since rL342102.
Reviewers: ruiu, espindola
Subscribers: emaste, arichardson, mgrang, llvm-commits
Differential Revision: https://reviews.llvm.org/D52569
llvm-svn: 343146
Diffstat (limited to 'lld/ELF/InputSection.cpp')
-rw-r--r-- | lld/ELF/InputSection.cpp | 13 |
1 files changed, 6 insertions, 7 deletions
diff --git a/lld/ELF/InputSection.cpp b/lld/ELF/InputSection.cpp index ca576291c6c..ddb968a326c 100644 --- a/lld/ELF/InputSection.cpp +++ b/lld/ELF/InputSection.cpp @@ -873,14 +873,13 @@ static void switchMorestackCallsToMorestackNonSplit( } // Sort both collections to compare addresses efficiently. - llvm::sort(MorestackCalls.begin(), MorestackCalls.end(), - [](const Relocation *L, const Relocation *R) { - return L->Offset < R->Offset; - }); + llvm::sort(MorestackCalls, [](const Relocation *L, const Relocation *R) { + return L->Offset < R->Offset; + }); std::vector<Defined *> Functions(Prologues.begin(), Prologues.end()); - llvm::sort( - Functions.begin(), Functions.end(), - [](const Defined *L, const Defined *R) { return L->Value < R->Value; }); + llvm::sort(Functions, [](const Defined *L, const Defined *R) { + return L->Value < R->Value; + }); auto It = MorestackCalls.begin(); for (Defined *F : Functions) { |