labath created this revision.
labath added a reviewer: clayborg.
labath added subscribers: tberghammer, lldb-commits.

void typedefs do not have a DW_AT_type attribute, so we end up with an empty 
encoding_uid
variable. These don't need to be looked up and trying to look that will assert 
in a debug build.

http://reviews.llvm.org/D22218

Files:
  source/Plugins/SymbolFile/DWARF/DWARFASTParserClang.cpp

Index: source/Plugins/SymbolFile/DWARF/DWARFASTParserClang.cpp
===================================================================
--- source/Plugins/SymbolFile/DWARF/DWARFASTParserClang.cpp
+++ source/Plugins/SymbolFile/DWARF/DWARFASTParserClang.cpp
@@ -328,7 +328,7 @@
                         }
                     }
 
-                    if (tag == DW_TAG_typedef)
+                    if (tag == DW_TAG_typedef && encoding_uid.IsValid())
                     {
                         // Try to parse a typedef from the DWO file first as 
modules
                         // can contain typedef'ed structures that have no 
names like:


Index: source/Plugins/SymbolFile/DWARF/DWARFASTParserClang.cpp
===================================================================
--- source/Plugins/SymbolFile/DWARF/DWARFASTParserClang.cpp
+++ source/Plugins/SymbolFile/DWARF/DWARFASTParserClang.cpp
@@ -328,7 +328,7 @@
                         }
                     }
 
-                    if (tag == DW_TAG_typedef)
+                    if (tag == DW_TAG_typedef && encoding_uid.IsValid())
                     {
                         // Try to parse a typedef from the DWO file first as modules
                         // can contain typedef'ed structures that have no names like:
_______________________________________________
lldb-commits mailing list
lldb-commits@lists.llvm.org
http://lists.llvm.org/cgi-bin/mailman/listinfo/lldb-commits

Reply via email to