[Lldb-commits] [lldb] r119910 - /lldb/trunk/source/Plugins/SymbolFile/DWARF/SymbolFileDWARF.cpp

Greg Clayton gclayton at apple.com
Sat Nov 20 11:16:50 PST 2010


Author: gclayton
Date: Sat Nov 20 13:16:50 2010
New Revision: 119910

URL: http://llvm.org/viewvc/llvm-project?rev=119910&view=rev
Log:
When we resolve a forward declaration type, be sure to put it into the m_die_to_type map so we don't assert later when someone tries to resolve the type.

Modified:
    lldb/trunk/source/Plugins/SymbolFile/DWARF/SymbolFileDWARF.cpp

Modified: lldb/trunk/source/Plugins/SymbolFile/DWARF/SymbolFileDWARF.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Plugins/SymbolFile/DWARF/SymbolFileDWARF.cpp?rev=119910&r1=119909&r2=119910&view=diff
==============================================================================
--- lldb/trunk/source/Plugins/SymbolFile/DWARF/SymbolFileDWARF.cpp (original)
+++ lldb/trunk/source/Plugins/SymbolFile/DWARF/SymbolFileDWARF.cpp Sat Nov 20 13:16:50 2010
@@ -3035,7 +3035,13 @@
                                 type_sp = m_debug_map_symfile->FindDefinitionTypeForDIE (dwarf_cu, die, type_name_const_str);
                         }
                         if (type_sp)
+                        {
+                            // We found a real definition for this type elsewhere
+                            // so lets use it and cache the fact that we found
+                            // a complete type for this die
+                            m_die_to_type[die] = type_sp.get();
                             return type_sp;
+                        }
                     }
                     assert (tag_decl_kind != -1);
                     bool clang_type_was_created = false;





More information about the lldb-commits mailing list