[lldb-dev] [PATCH] Disable builtin demangler on msvc builds
Colin Riley
colin at codeplay.com
Fri Nov 15 03:11:31 PST 2013
Just realised I sent this to the wrong list previously. Anyone able to
put it in on the quick? Or do we need to review a change as small as this?
Cheers,
Colin
On 13/11/2013 15:32, Colin Riley wrote:
> The demangler added in r193708 from cxa_demangle.cpp uses language
> features which are not supported by the latest visual studio. In order
> to preserve the msvc build, this patch restores the previous
> (non)functionality in windows under msvc by disabling the demangler.
>
>
> _______________________________________________
> lldb-commits mailing list
> lldb-commits at cs.uiuc.edu
> http://lists.cs.uiuc.edu/mailman/listinfo/lldb-commits
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/lldb-dev/attachments/20131115/2accd9ea/attachment.html>
-------------- next part --------------
Index: source/Core/Mangled.cpp
===================================================================
--- source/Core/Mangled.cpp (revision 194563)
+++ source/Core/Mangled.cpp (working copy)
@@ -10,7 +10,9 @@
// FreeBSD9-STABLE requires this to know about size_t in cxxabi.h
#include <cstddef>
-#if defined(_MSC_VER) || defined (__FreeBSD__)
+#if defined(_MSC_VER)
+// Cannot enable the builtin demangler on msvc as it does not support the cpp11 within the implementation.
+#elif defined (__FreeBSD__)
#define LLDB_USE_BUILTIN_DEMANGLER
#else
#include <cxxabi.h>
@@ -4890,6 +4892,9 @@
// add it to our map.
#ifdef LLDB_USE_BUILTIN_DEMANGLER
char *demangled_name = __cxa_demangle (mangled_cstr, NULL, NULL, NULL);
+#elif defined(_MSC_VER)
+ // Cannot demangle on msvc.
+ char *demangled_name = nullptr;
#else
char *demangled_name = abi::__cxa_demangle (mangled_cstr, NULL, NULL, NULL);
#endif
More information about the lldb-dev
mailing list