From c6d940a9569deb4a89a5628caa78b1ccfcfd2bdf Mon Sep 17 00:00:00 2001 From: Simon Marchi Date: Mon, 14 Sep 2020 11:07:57 -0400 Subject: gdb: remove TYPE_UNSIGNED gdb/ChangeLog: * gdbtypes.h (TYPE_UNSIGNED): Remove, replace all uses with type::is_unsigned. Change-Id: I84f76f5cd44ff7294e421d317376a9e476bc8666 --- gdb/compile/compile-c-support.c | 2 +- gdb/compile/compile-c-types.c | 6 +++--- gdb/compile/compile-cplus-types.c | 4 ++-- 3 files changed, 6 insertions(+), 6 deletions(-) (limited to 'gdb/compile') diff --git a/gdb/compile/compile-c-support.c b/gdb/compile/compile-c-support.c index 5e4da67..636ac84 100644 --- a/gdb/compile/compile-c-support.c +++ b/gdb/compile/compile-c-support.c @@ -256,7 +256,7 @@ generate_register_struct (struct ui_file *stream, struct gdbarch *gdbarch, if (mode != NULL) { - if (TYPE_UNSIGNED (regtype)) + if (regtype->is_unsigned ()) fputs_unfiltered ("unsigned ", stream); fprintf_unfiltered (stream, "int %s" diff --git a/gdb/compile/compile-c-types.c b/gdb/compile/compile-c-types.c index 2b25783..a34550a 100644 --- a/gdb/compile/compile-c-types.c +++ b/gdb/compile/compile-c-types.c @@ -130,7 +130,7 @@ convert_enum (compile_c_instance *context, struct type *type) gcc_type int_type, result; int i; - int_type = context->plugin ().int_type_v0 (TYPE_UNSIGNED (type), + int_type = context->plugin ().int_type_v0 (type->is_unsigned (), TYPE_LENGTH (type)); result = context->plugin ().build_enum_type (int_type); @@ -199,12 +199,12 @@ convert_int (compile_c_instance *context, struct type *type) gdb_assert (TYPE_LENGTH (type) == 1); return context->plugin ().char_type (); } - return context->plugin ().int_type (TYPE_UNSIGNED (type), + return context->plugin ().int_type (type->is_unsigned (), TYPE_LENGTH (type), type->name ()); } else - return context->plugin ().int_type_v0 (TYPE_UNSIGNED (type), + return context->plugin ().int_type_v0 (type->is_unsigned (), TYPE_LENGTH (type)); } diff --git a/gdb/compile/compile-cplus-types.c b/gdb/compile/compile-cplus-types.c index 02df7ab..647cfc5 100644 --- a/gdb/compile/compile-cplus-types.c +++ b/gdb/compile/compile-cplus-types.c @@ -929,7 +929,7 @@ compile_cplus_convert_enum (compile_cplus_instance *instance, struct type *type, instance->enter_scope (std::move (scope)); gcc_type int_type - = instance->plugin ().get_int_type (TYPE_UNSIGNED (type), + = instance->plugin ().get_int_type (type->is_unsigned (), TYPE_LENGTH (type), nullptr); gcc_type result = instance->plugin ().start_enum_type (name.get (), int_type, @@ -1022,7 +1022,7 @@ compile_cplus_convert_int (compile_cplus_instance *instance, struct type *type) } return instance->plugin ().get_int_type - (TYPE_UNSIGNED (type), TYPE_LENGTH (type), type->name ()); + (type->is_unsigned (), TYPE_LENGTH (type), type->name ()); } /* Convert a floating-point type to its gcc representation. */ -- cgit v1.1