]> granicus.if.org Git - clang/commitdiff
[clang] Change to range-based invocation of llvm::sort
authorMandeep Singh Grang <mgrang@codeaurora.org>
Fri, 18 Jan 2019 18:45:26 +0000 (18:45 +0000)
committerMandeep Singh Grang <mgrang@codeaurora.org>
Fri, 18 Jan 2019 18:45:26 +0000 (18:45 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/cfe/trunk@351573 91177308-0d34-0410-b5e6-96231b3b80d8

lib/Format/Format.cpp

index 2c4f8760540a4b88d74b23ae142ce9773a484c7e..705b8d7a1a944e05d8e357637761cddd4e908e5c 100644 (file)
@@ -1868,7 +1868,7 @@ static void sortJavaImports(const FormatStyle &Style,
     JavaImportGroups.push_back(
         findJavaImportGroup(Style, Imports[i].Identifier));
   }
-  llvm::sort(Indices.begin(), Indices.end(), [&](unsigned LHSI, unsigned RHSI) {
+  llvm::sort(Indices, [&](unsigned LHSI, unsigned RHSI) {
         // Negating IsStatic to push static imports above non-static imports.
         return std::make_tuple(!Imports[LHSI].IsStatic, JavaImportGroups[LHSI],
                                Imports[LHSI].Identifier) <