[PATCH] D57350: [llvm-cxxfilt] Split input and demangle each word.

James Henderson via Phabricator via llvm-commits llvm-commits at lists.llvm.org
Tue Jan 29 01:30:26 PST 2019


jhenderson added reviewers: jhenderson, davide.
jhenderson added inline comments.


================
Comment at: llvm/test/tools/llvm-cxxfilt/types.test:2
 RUN: llvm-cxxfilt -t f i | FileCheck %s
+RUN: llvm-cxxfilt -t "f i" | FileCheck %s --check-prefix="CHECK-STRING"
 
----------------
You probably don't need this test, as it doesn't test any different functionality than the first test.


================
Comment at: llvm/tools/llvm-cxxfilt/llvm-cxxfilt.cpp:9-11
+#include "llvm/ADT/SmallVector.h"
+#include "llvm/ADT/StringExtras.h"
+#include "llvm/ADT/StringRef.h"
----------------
I'm not sure you need (some of) these headers, even if you use them, by my understanding of the coding guidelines, because e.g. CommandLine.h includes them: https://llvm.org/docs/CodingStandards.html#include-as-little-as-possible


================
Comment at: llvm/tools/llvm-cxxfilt/llvm-cxxfilt.cpp:85
+// The result is reconstructed and output to 'OS'.
+static void demangleLine(llvm::raw_ostream &OS, const std::string &Mangled) {
+  SmallVector<StringRef, 16> Words;
----------------
`Mangled` should be a `StringRef`.


CHANGES SINCE LAST ACTION
  https://reviews.llvm.org/D57350/new/

https://reviews.llvm.org/D57350





More information about the llvm-commits mailing list