[Lldb-commits] [lldb] r131473 - /lldb/trunk/source/Symbol/ClangASTContext.cpp

Greg Clayton gclayton at apple.com
Tue May 17 11:15:05 PDT 2011


Author: gclayton
Date: Tue May 17 13:15:05 2011
New Revision: 131473

URL: http://llvm.org/viewvc/llvm-project?rev=131473&view=rev
Log:
Fixed an assert that could cause a crash when there was an
unrecognized DW_TAG_base_type. Now it is a error printed to
stderr.


Modified:
    lldb/trunk/source/Symbol/ClangASTContext.cpp

Modified: lldb/trunk/source/Symbol/ClangASTContext.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Symbol/ClangASTContext.cpp?rev=131473&r1=131472&r2=131473&view=diff
==============================================================================
--- lldb/trunk/source/Symbol/ClangASTContext.cpp (original)
+++ lldb/trunk/source/Symbol/ClangASTContext.cpp Tue May 17 13:15:05 2011
@@ -862,7 +862,14 @@
     }
     // This assert should fire for anything that we don't catch above so we know
     // to fix any issues we run into.
-    assert (!"error: ClangASTContext::GetClangTypeForDWARFEncodingAndSize() contains an unhandled encoding. Fix this ASAP!");
+    if (type_name)
+    {
+        fprintf (stderr, "error: need to add support for DW_TAG_base_type '%s' encoded with DW_ATE = 0x%x, bit_size = %u\n", type_name, dw_ate, bit_size);
+    }
+    else
+    {
+        fprintf (stderr, "error: need to add support for DW_TAG_base_type encoded with DW_ATE = 0x%x, bit_size = %u\n", dw_ate, bit_size);
+    }
     return NULL;
 }
 





More information about the lldb-commits mailing list