This is the mail archive of the
gdb-testers@sourceware.org
mailing list for the GDB project.
[binutils-gdb] Move ptype/o printing code to typeprint.c
- From: sergiodj+buildbot at sergiodj dot net
- To: gdb-testers at sourceware dot org
- Date: Tue, 26 Jun 2018 17:14:31 -0400
- Subject: [binutils-gdb] Move ptype/o printing code to typeprint.c
*** TEST RESULTS FOR COMMIT e0c547d14ae1d5c06b59178f4b1dd1f5e08b3feb ***
Author: Tom Tromey <tom@tromey.com>
Branch: master
Commit: e0c547d14ae1d5c06b59178f4b1dd1f5e08b3feb
Move ptype/o printing code to typeprint.c
This moves the hole-printing support code for ptype/o from
c-typeprint.c to be methods on print_offset_data. This allows the
code to be used from non-C languages.
gdb/ChangeLog
2018-06-26 Tom Tromey <tom@tromey.com>
* typeprint.h (struct print_offset_data) <update, finish,
maybe_print_hole>: New methods.
<indentation>: New constant.
* typeprint.c (print_offset_data::indentation): Define.
(print_offset_data::maybe_print_hole, print_offset_data::update)
(print_offset_data::finish): Move from c-typeprint.c and rename.
* c-typeprint.c (OFFSET_SPC_LEN): Remove.
(print_spaces_filtered_with_print_options): Update.
(c_print_type_union_field_offset, maybe_print_hole)
(c_print_type_struct_field_offset): Move to typeprint.c and
rename.
(c_type_print_base_struct_union): Update.