From 82216048e6bcdf2e37b356e45954ac8cdceaab50 Mon Sep 17 00:00:00 2001 From: Fangrui Song Date: Fri, 19 Apr 2019 05:49:29 +0000 Subject: [PATCH] [MergeFunc] Use less_first() as the comparator of Schwartzian transform llvm-svn: 358738 --- llvm/lib/Transforms/IPO/MergeFunctions.cpp | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/llvm/lib/Transforms/IPO/MergeFunctions.cpp b/llvm/lib/Transforms/IPO/MergeFunctions.cpp index d0c1613..8a40f04 100644 --- a/llvm/lib/Transforms/IPO/MergeFunctions.cpp +++ b/llvm/lib/Transforms/IPO/MergeFunctions.cpp @@ -403,12 +403,7 @@ bool MergeFunctions::runOnModule(Module &M) { } } - std::stable_sort( - HashedFuncs.begin(), HashedFuncs.end(), - [](const std::pair &a, - const std::pair &b) { - return a.first < b.first; - }); + std::stable_sort(HashedFuncs.begin(), HashedFuncs.end(), less_first()); auto S = HashedFuncs.begin(); for (auto I = HashedFuncs.begin(), IE = HashedFuncs.end(); I != IE; ++I) { -- 2.7.4