OSDN Git Service

Try to fix build break due to template argument deduction.
authorZachary Turner <zturner@google.com>
Wed, 15 Mar 2017 22:32:59 +0000 (22:32 +0000)
committerZachary Turner <zturner@google.com>
Wed, 15 Mar 2017 22:32:59 +0000 (22:32 +0000)
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@297902 91177308-0d34-0410-b5e6-96231b3b80d8

tools/llvm-pdbdump/Diff.cpp

index 6ad235a..2b020ef 100644 (file)
@@ -54,11 +54,12 @@ static void set_differences(Range &&R1, Range &&R2,
   }
 }
 
-template<typename Range>
-static void set_differences(Range &&R1, Range &&R2,
-  SmallVectorImpl<ValueOfRange<Range>> *OnlyLeft,
-  SmallVectorImpl<ValueOfRange<Range>> *OnlyRight,
-  SmallVectorImpl<ValueOfRange<Range>> *Intersection) {
+template <typename Range>
+static void
+set_differences(Range &&R1, Range &&R2,
+                SmallVectorImpl<ValueOfRange<Range>> *OnlyLeft,
+                SmallVectorImpl<ValueOfRange<Range>> *OnlyRight,
+                SmallVectorImpl<ValueOfRange<Range>> *Intersection = nullptr) {
   std::less<ValueOfRange<Range>> Comp;
   set_differences(std::forward<Range>(R1), std::forward<Range>(R2), OnlyLeft, OnlyRight, Intersection, Comp);
 }
@@ -338,7 +339,7 @@ Error DiffStyle::diffStringTable() {
     SmallVector<StringRef, 64> OnlyP;
     SmallVector<StringRef, 64> OnlyQ;
 
-    set_differences(Strings1, Strings2, &OnlyP, &OnlyQ, nullptr);
+    set_differences(Strings1, Strings2, &OnlyP, &OnlyQ);
 
     if (!OnlyP.empty()) {
       HasDiff = true;