diff options
author | Tom Tromey <tom@tromey.com> | 2023-01-31 07:52:09 -0700 |
---|---|---|
committer | Tom Tromey <tom@tromey.com> | 2023-02-13 15:21:06 -0700 |
commit | d0c9791728caa0d3b3270a997c7fd97919976c97 (patch) | |
tree | 1753b7232efa89e05696d4289d60ad019fc161e4 /gdb/typeprint.c | |
parent | 7cf57bc5be656c62cc6b80280a9eddad2b8ded3f (diff) | |
download | gdb-d0c9791728caa0d3b3270a997c7fd97919976c97.zip gdb-d0c9791728caa0d3b3270a997c7fd97919976c97.tar.gz gdb-d0c9791728caa0d3b3270a997c7fd97919976c97.tar.bz2 |
Turn value_type into method
This changes value_type to be a method of value. Much of this patch
was written by script.
Approved-By: Simon Marchi <simon.marchi@efficios.com>
Diffstat (limited to 'gdb/typeprint.c')
-rw-r--r-- | gdb/typeprint.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/gdb/typeprint.c b/gdb/typeprint.c index 41b5735..64709b9 100644 --- a/gdb/typeprint.c +++ b/gdb/typeprint.c @@ -515,7 +515,7 @@ whatis_exp (const char *exp, int show) any typedef level. "ptype" always strips all levels of typedefs. */ val = evaluate_type (expr.get ()); - type = value_type (val); + type = val->type (); if (show == -1 && expr->first_opcode () == OP_TYPE) { @@ -536,7 +536,7 @@ whatis_exp (const char *exp, int show) else { val = access_value_history (0); - type = value_type (val); + type = val->type (); } if (flags.print_offsets && is_dynamic_type (type)) @@ -712,7 +712,7 @@ maintenance_print_type (const char *type_name, int from_tty) { expression_up expr = parse_expression (type_name); struct value *val = evaluate_type (expr.get ()); - struct type *type = value_type (val); + struct type *type = val->type (); if (type != nullptr) recursive_dump_type (type, 0); |