[llvm-pdbdump] Fix GCC build.
authorZachary Turner <zturner@google.com>
Sun, 1 Mar 2015 06:59:57 +0000 (06:59 +0000)
committerZachary Turner <zturner@google.com>
Sun, 1 Mar 2015 06:59:57 +0000 (06:59 +0000)
llvm-svn: 230890

llvm/tools/llvm-pdbdump/LinePrinter.h

index 003e847..51b4fa9 100644 (file)
@@ -10,6 +10,7 @@
 #ifndef LLVM_TOOLS_LLVMPDBDUMP_LINEPRINTER_H
 #define LLVM_TOOLS_LLVMPDBDUMP_LINEPRINTER_H
 
+#include "llvm/ADT/StringRef.h"
 #include "llvm/ADT/Twine.h"
 #include "llvm/Support/raw_ostream.h"
 #include "llvm/Support/Regex.h"
@@ -25,13 +26,19 @@ public:
   LinePrinter(int Indent, raw_ostream &Stream);
 
   template <typename Iter> void SetTypeFilters(Iter Begin, Iter End) {
-    TypeFilters.assign(Begin, End);
+    TypeFilters.clear();
+    for (; Begin != End; ++Begin)
+      TypeFilters.push_back(StringRef(*Begin));
   }
   template <typename Iter> void SetSymbolFilters(Iter Begin, Iter End) {
-    SymbolFilters.assign(Begin, End);
+    SymbolFilters.clear();
+    for (; Begin != End; ++Begin)
+      SymbolFilters.push_back(StringRef(*Begin));
   }
   template <typename Iter> void SetCompilandFilters(Iter Begin, Iter End) {
-    CompilandFilters.assign(Begin, End);
+    CompilandFilters.clear();
+    for (; Begin != End; ++Begin)
+      CompilandFilters.push_back(StringRef(*Begin));
   }
 
   void Indent();