diff options
author | Tom Tromey <tom@tromey.com> | 2023-04-22 12:41:43 -0600 |
---|---|---|
committer | Tom Tromey <tom@tromey.com> | 2023-05-01 09:20:37 -0600 |
commit | c819a3380fc1b110b88bc6ab5ef9323dbe7d4753 (patch) | |
tree | 05450117dff9b07e36d3ddb7bddf2fd88651c543 /gdb/p-valprint.c | |
parent | 077a1f08485e88f3b234af1dbb8b907b16045e6a (diff) | |
download | gdb-c819a3380fc1b110b88bc6ab5ef9323dbe7d4753.zip gdb-c819a3380fc1b110b88bc6ab5ef9323dbe7d4753.tar.gz gdb-c819a3380fc1b110b88bc6ab5ef9323dbe7d4753.tar.bz2 |
Replace field_is_static with a method
This changes field_is_static to be a method on struct field, and
updates all the callers. Most of this patch was written by script.
Regression tested on x86-64 Fedora 36.
Diffstat (limited to 'gdb/p-valprint.c')
-rw-r--r-- | gdb/p-valprint.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/gdb/p-valprint.c b/gdb/p-valprint.c index d74c738..2136a192 100644 --- a/gdb/p-valprint.c +++ b/gdb/p-valprint.c @@ -553,7 +553,7 @@ pascal_object_print_value_fields (struct value *val, struct ui_file *stream, { /* If requested, skip printing of static fields. */ if (!options->pascal_static_field_print - && field_is_static (&type->field (i))) + && type->field (i).is_static ()) continue; if (fields_seen) gdb_printf (stream, ", "); @@ -582,7 +582,7 @@ pascal_object_print_value_fields (struct value *val, struct ui_file *stream, annotate_field_begin (type->field (i).type ()); - if (field_is_static (&type->field (i))) + if (type->field (i).is_static ()) { gdb_puts ("static ", stream); fprintf_symbol (stream, @@ -597,7 +597,7 @@ pascal_object_print_value_fields (struct value *val, struct ui_file *stream, gdb_puts (" = ", stream); annotate_field_value (); - if (!field_is_static (&type->field (i)) + if (!type->field (i).is_static () && TYPE_FIELD_PACKED (type, i)) { struct value *v; @@ -634,7 +634,7 @@ pascal_object_print_value_fields (struct value *val, struct ui_file *stream, fputs_styled ("<optimized out or zero length>", metadata_style.style (), stream); } - else if (field_is_static (&type->field (i))) + else if (type->field (i).is_static ()) { /* struct value *v = value_static_field (type, i); v4.17 specific. */ |