tools: fix gdb pretty printers

needed after merging 5c3325588ef4e85e85cb201ad9328fe26bbb8dca.
This commit is contained in:
Andrew Kelley 2022-03-20 00:34:40 -07:00
parent 6d73f89bf1
commit 3ef34feaeb

View File

@ -9,47 +9,47 @@ class TypePrinter:
# Keep in sync with src/type.zig # Keep in sync with src/type.zig
# Types which have no payload do not need to be entered here. # Types which have no payload do not need to be entered here.
payload_type_names = { payload_type_names = {
'array_u8': 'type.Len', 'array_u8': 'Type.Payload.Len',
'array_u8_sentinel_0': 'Len', 'array_u8_sentinel_0': 'Type.Payload.Len',
'single_const_pointer': 'ElemType', 'single_const_pointer': 'Type.Payload.ElemType',
'single_mut_pointer': 'ElemType', 'single_mut_pointer': 'Type.Payload.ElemType',
'many_const_pointer': 'ElemType', 'many_const_pointer': 'Type.Payload.ElemType',
'many_mut_pointer': 'ElemType', 'many_mut_pointer': 'Type.Payload.ElemType',
'c_const_pointer': 'ElemType', 'c_const_pointer': 'Type.Payload.ElemType',
'c_mut_pointer': 'ElemType', 'c_mut_pointer': 'Type.Payload.ElemType',
'const_slice': 'ElemType', 'const_slice': 'Type.Payload.ElemType',
'mut_slice': 'ElemType', 'mut_slice': 'Type.Payload.ElemType',
'optional': 'ElemType', 'optional': 'Type.Payload.ElemType',
'optional_single_mut_pointer': 'ElemType', 'optional_single_mut_pointer': 'Type.Payload.ElemType',
'optional_single_const_pointer': 'ElemType', 'optional_single_const_pointer': 'Type.Payload.ElemType',
'anyframe_T': 'ElemType', 'anyframe_T': 'Type.Payload.ElemType',
'int_signed': 'Bits', 'int_signed': 'Type.Payload.Bits',
'int_unsigned': 'Bits', 'int_unsigned': 'Type.Payload.Bits',
'error_set': 'ErrorSet', 'error_set': 'Type.Payload.ErrorSet',
'error_set_inferred': 'ErrorSetInferred', 'error_set_inferred': 'Type.Payload.ErrorSetInferred',
'error_set_merged': 'ErrorSetMerged', 'error_set_merged': 'Type.Payload.ErrorSetMerged',
'array': 'Array', 'array': 'Type.Payload.Array',
'vector': 'Array', 'vector': 'Type.Payload.Array',
'array_sentinel': 'ArraySentinel', 'array_sentinel': 'Type.Payload.ArraySentinel',
'pointer': 'Pointer', 'pointer': 'Type.Payload.Pointer',
'function': 'Function', 'function': 'Type.Payload.Function',
'error_union': 'ErrorUnion', 'error_union': 'Type.Payload.ErrorUnion',
'error_set_single': 'Name', 'error_set_single': 'Type.Payload.Name',
'opaque': 'Opaque', 'opaque': 'Type.Payload.Opaque',
'struct': 'Struct', 'struct': 'Type.Payload.Struct',
'union': 'Union', 'union': 'Type.Payload.Union',
'union_tagged': 'Union', 'union_tagged': 'Type.Payload.Union',
'enum_full, .enum_nonexhaustive': 'EnumFull', 'enum_full, .enum_nonexhaustive': 'Type.Payload.EnumFull',
'enum_simple': 'EnumSimple', 'enum_simple': 'Type.Payload.EnumSimple',
'enum_numbered': 'EnumNumbered', 'enum_numbered': 'Type.Payload.EnumNumbered',
'empty_struct': 'ContainerScope', 'empty_struct': 'Type.Payload.ContainerScope',
'tuple': 'Tuple', 'tuple': 'Type.Payload.Tuple',
'anon_struct': 'AnonStruct', 'anon_struct': 'Type.Payload.AnonStruct',
} }
def __init__(self, val): def __init__(self, val):
@ -98,48 +98,48 @@ class ValuePrinter:
# Keep in sync with src/value.zig # Keep in sync with src/value.zig
# Values which have no payload do not need to be entered here. # Values which have no payload do not need to be entered here.
payload_type_names = { payload_type_names = {
'big_int_positive': 'BigInt', 'big_int_positive': 'Value.Payload.BigInt',
'big_int_negative': 'BigInt', 'big_int_negative': 'Value.Payload.BigInt',
'extern_fn': 'ExternFn', 'extern_fn': 'Value.Payload.ExternFn',
'decl_ref': 'Decl', 'decl_ref': 'Value.Payload.Decl',
'repeated': 'SubValue', 'repeated': 'Value.Payload.SubValue',
'eu_payload': 'SubValue', 'eu_payload': 'Value.Payload.SubValue',
'opt_payload': 'SubValue', 'opt_payload': 'Value.Payload.SubValue',
'empty_array_sentinel': 'SubValue', 'empty_array_sentinel': 'Value.Payload.SubValue',
'eu_payload_ptr': 'PayloadPtr', 'eu_payload_ptr': 'Value.Payload.PayloadPtr',
'opt_payload_ptr': 'PayloadPtr', 'opt_payload_ptr': 'Value.Payload.PayloadPtr',
'bytes': 'Bytes', 'bytes': 'Value.Payload.Bytes',
'enum_literal': 'Bytes', 'enum_literal': 'Value.Payload.Bytes',
'slice': 'Slice', 'slice': 'Value.Payload.Slice',
'enum_field_index': 'U32', 'enum_field_index': 'Value.Payload.U32',
'ty': 'Ty', 'ty': 'Value.Payload.Ty',
'int_type': 'IntType', 'int_type': 'Value.Payload.IntType',
'int_u64': 'U64', 'int_u64': 'Value.Payload.U64',
'int_i64': 'I64', 'int_i64': 'Value.Payload.I64',
'function': 'Function', 'function': 'Value.Payload.Function',
'variable': 'Variable', 'variable': 'Value.Payload.Variable',
'decl_ref_mut': 'DeclRefMut', 'decl_ref_mut': 'Value.Payload.DeclRefMut',
'elem_ptr': 'ElemPtr', 'elem_ptr': 'Value.Payload.ElemPtr',
'field_ptr': 'FieldPtr', 'field_ptr': 'Value.Payload.FieldPtr',
'float_16': 'Float_16', 'float_16': 'Value.Payload.Float_16',
'float_32': 'Float_32', 'float_32': 'Value.Payload.Float_32',
'float_64': 'Float_64', 'float_64': 'Value.Payload.Float_64',
'float_80': 'Float_80', 'float_80': 'Value.Payload.Float_80',
'float_128': 'Float_128', 'float_128': 'Value.Payload.Float_128',
'error': 'Error', 'error': 'Value.Payload.Error',
'inferred_alloc': 'InferredAlloc', 'inferred_alloc': 'Value.Payload.InferredAlloc',
'inferred_alloc_comptime': 'InferredAllocComptime', 'inferred_alloc_comptime': 'Value.Payload.InferredAllocComptime',
'aggregate': 'Aggregate', 'aggregate': 'Value.Payload.Aggregate',
'union': 'Union', 'union': 'Value.Payload.Union',
'bound_fn': 'BoundFn', 'bound_fn': 'Value.Payload.BoundFn',
} }
def __init__(self, val): def __init__(self, val):