[clang-tools-extra] r341362 - Remove lambda default parameter to silence -Wpedantic warning. NFCI.

Simon Pilgrim via cfe-commits cfe-commits at lists.llvm.org
Tue Sep 4 05:17:10 PDT 2018


Author: rksimon
Date: Tue Sep  4 05:17:10 2018
New Revision: 341362

URL: http://llvm.org/viewvc/llvm-project?rev=341362&view=rev
Log:
Remove lambda default parameter to silence -Wpedantic warning. NFCI.

Modified:
    clang-tools-extra/trunk/clangd/CodeComplete.cpp

Modified: clang-tools-extra/trunk/clangd/CodeComplete.cpp
URL: http://llvm.org/viewvc/llvm-project/clang-tools-extra/trunk/clangd/CodeComplete.cpp?rev=341362&r1=341361&r2=341362&view=diff
==============================================================================
--- clang-tools-extra/trunk/clangd/CodeComplete.cpp (original)
+++ clang-tools-extra/trunk/clangd/CodeComplete.cpp Tue Sep  4 05:17:10 2018
@@ -1414,7 +1414,7 @@ private:
     llvm::DenseMap<size_t, size_t> BundleLookup;
     auto AddToBundles = [&](const CodeCompletionResult *SemaResult,
                             const Symbol *IndexResult,
-                            bool IsOverride = false) {
+                            bool IsOverride) {
       CompletionCandidate C;
       C.SemaResult = SemaResult;
       C.IndexResult = IndexResult;
@@ -1446,7 +1446,7 @@ private:
     };
     // Emit all Sema results, merging them with Index results if possible.
     for (auto &SemaResult : Recorder->Results)
-      AddToBundles(&SemaResult, CorrespondingIndexResult(SemaResult));
+      AddToBundles(&SemaResult, CorrespondingIndexResult(SemaResult), false);
     // Handle OverrideResults the same way we deal with SemaResults. Since these
     // results use the same structs as a SemaResult it is safe to do that, but
     // we need to make sure we dont' duplicate things in future if Sema starts
@@ -1458,7 +1458,7 @@ private:
     for (const auto &IndexResult : IndexResults) {
       if (UsedIndexResults.count(&IndexResult))
         continue;
-      AddToBundles(/*SemaResult=*/nullptr, &IndexResult);
+      AddToBundles(/*SemaResult=*/nullptr, &IndexResult, false);
     }
     // We only keep the best N results at any time, in "native" format.
     TopN<ScoredBundle, ScoredBundleGreater> Top(




More information about the cfe-commits mailing list