[PATCH] D19135: [sanitizers] Teach the internal demangler about Swift names
Mike Aizatsky via llvm-commits
llvm-commits at lists.llvm.org
Fri Apr 15 11:04:11 PDT 2016
aizatsky added inline comments.
================
Comment at: lib/sanitizer_common/sanitizer_symbolizer_internal.h:31
@@ -30,3 +30,3 @@
-const char *DemangleCXXABI(const char *name);
+const char *DemangleCXXAndSwift(const char *name);
----------------
should probably be DemangleSwiftAndCXX because of the demangling order.
================
Comment at: lib/sanitizer_common/tests/sanitizer_symbolizer_test.cc:59
@@ +58,3 @@
+TEST(Symbolizer, DemangleCXXAndSwift) {
+ // The Swift name will only be demangled if the Swift runtime is linked in.
+ EXPECT_STREQ("_TtSd", DemangleCXXAndSwift("_TtSd"));
----------------
Let's have two separate test cases: DemangleCXX and DemangleSwift.
Let's also make the comment a statement.
// Swift names are not demangled in default llvm build because Swift runtime is not linked in.
http://reviews.llvm.org/D19135
More information about the llvm-commits
mailing list