From: Ulrich Weigand Date: Thu, 2 Jul 2009 12:16:56 +0000 (+0000) Subject: * m2-typeprint.c (m2_print_bounds, m2_is_long_set_of_type): Remove X-Git-Tag: msnyder-checkpoint-072509-branchpoint~246 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=d5c831bd769fa23e1f0d6c7e9ac9efbad0f84a6d;p=external%2Fbinutils.git * m2-typeprint.c (m2_print_bounds, m2_is_long_set_of_type): Remove redundant check for NULL TYPE_TARGET_TYPE. * m2-valprint.c (m2_print_long_set): Likewise. * p-valprint.c (pascal_type_print_base): Likewise. --- diff --git a/gdb/ChangeLog b/gdb/ChangeLog index 4fb5695..935a29f 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,5 +1,12 @@ 2009-07-02 Ulrich Weigand + * m2-typeprint.c (m2_print_bounds, m2_is_long_set_of_type): Remove + redundant check for NULL TYPE_TARGET_TYPE. + * m2-valprint.c (m2_print_long_set): Likewise. + * p-valprint.c (pascal_type_print_base): Likewise. + +2009-07-02 Ulrich Weigand + * printcmd.c (next_gdbarch): New static variable. (set_next_address, do_examine, x_command): Set it. (decode_format): Use 'a' size to indicate width of an address. diff --git a/gdb/m2-typeprint.c b/gdb/m2-typeprint.c index 162ef9f..8c5d6b4 100644 --- a/gdb/m2-typeprint.c +++ b/gdb/m2-typeprint.c @@ -307,9 +307,6 @@ m2_print_bounds (struct type *type, { struct type *target = TYPE_TARGET_TYPE (type); - if (target == NULL) - target = builtin_type_int32; - if (TYPE_NFIELDS(type) == 0) return; @@ -414,8 +411,6 @@ m2_is_long_set_of_type (struct type *type, struct type **of_type) return 0; range = TYPE_INDEX_TYPE (TYPE_FIELD_TYPE (type, i)); target = TYPE_TARGET_TYPE (range); - if (target == NULL) - target = builtin_type_int32; l1 = TYPE_LOW_BOUND (TYPE_INDEX_TYPE (TYPE_FIELD_TYPE (type, i))); h1 = TYPE_HIGH_BOUND (TYPE_INDEX_TYPE (TYPE_FIELD_TYPE (type, len-1))); diff --git a/gdb/m2-valprint.c b/gdb/m2-valprint.c index 41fb8fe..27b0e8a 100644 --- a/gdb/m2-valprint.c +++ b/gdb/m2-valprint.c @@ -119,8 +119,6 @@ m2_print_long_set (struct type *type, const gdb_byte *valaddr, } target = TYPE_TARGET_TYPE (range); - if (target == NULL) - target = builtin_type_int32; if (get_discrete_bounds (range, &field_low, &field_high) >= 0) { @@ -165,8 +163,6 @@ m2_print_long_set (struct type *type, const gdb_byte *valaddr, if (get_discrete_bounds (range, &field_low, &field_high) < 0) break; target = TYPE_TARGET_TYPE (range); - if (target == NULL) - target = builtin_type_int32; } } if (element_seen) diff --git a/gdb/p-typeprint.c b/gdb/p-typeprint.c index 5085fb4..62f4511 100644 --- a/gdb/p-typeprint.c +++ b/gdb/p-typeprint.c @@ -768,8 +768,6 @@ pascal_type_print_base (struct type *type, struct ui_file *stream, int show, case TYPE_CODE_RANGE: { struct type *target = TYPE_TARGET_TYPE (type); - if (target == NULL) - target = builtin_type_int32; print_type_scalar (target, TYPE_LOW_BOUND (type), stream); fputs_filtered ("..", stream); print_type_scalar (target, TYPE_HIGH_BOUND (type), stream);