Skip to content

Commit d443641

Browse files
author
Greg Clayton
committed
Added support for the C++Ox "nullptr_t" type.
llvm-svn: 143225
1 parent 07ae229 commit d443641

File tree

2 files changed

+12
-0
lines changed

2 files changed

+12
-0
lines changed

lldb/source/Plugins/SymbolFile/DWARF/DWARFCompileUnit.cpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -660,6 +660,7 @@ DWARFCompileUnit::Index (const uint32_t cu_idx,
660660
case DW_TAG_typedef:
661661
case DW_TAG_namespace:
662662
case DW_TAG_variable:
663+
case DW_TAG_unspecified_type:
663664
break;
664665

665666
default:
@@ -889,6 +890,7 @@ DWARFCompileUnit::Index (const uint32_t cu_idx,
889890
case DW_TAG_structure_type:
890891
case DW_TAG_union_type:
891892
case DW_TAG_typedef:
893+
case DW_TAG_unspecified_type:
892894
if (name && is_declaration == false)
893895
{
894896
types.Insert (ConstString(name), die.GetOffset());

lldb/source/Plugins/SymbolFile/DWARF/SymbolFileDWARF.cpp

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3808,6 +3808,7 @@ SymbolFileDWARF::ParseType (const SymbolContext& sc, DWARFCompileUnit* dwarf_cu,
38083808
case DW_TAG_const_type:
38093809
case DW_TAG_restrict_type:
38103810
case DW_TAG_volatile_type:
3811+
case DW_TAG_unspecified_type:
38113812
{
38123813
// Set a bit that lets us know that we are currently parsing this
38133814
m_die_to_type[die] = DIE_IS_BEING_PARSED;
@@ -3861,6 +3862,15 @@ SymbolFileDWARF::ParseType (const SymbolContext& sc, DWARFCompileUnit* dwarf_cu,
38613862
default:
38623863
break;
38633864

3865+
case DW_TAG_unspecified_type:
3866+
if (strcmp(type_name_cstr, "nullptr_t") == 0)
3867+
{
3868+
resolve_state = Type::eResolveStateFull;
3869+
clang_type = ast.getASTContext()->NullPtrTy.getAsOpaquePtr();
3870+
break;
3871+
}
3872+
// Fall through to base type below in case we can handle the type there...
3873+
38643874
case DW_TAG_base_type:
38653875
resolve_state = Type::eResolveStateFull;
38663876
clang_type = ast.GetBuiltinTypeForDWARFEncodingAndBitSize (type_name_cstr,

0 commit comments

Comments
 (0)