diff options
author | Tom Tromey <tom@tromey.com> | 2017-04-12 16:30:21 -0600 |
---|---|---|
committer | Tom Tromey <tom@tromey.com> | 2017-04-22 09:47:01 -0600 |
commit | 10f489e57677e670bf980e93896762594e9ad908 (patch) | |
tree | baaeb8059b91d5eac4e0b633f65d6b64f220d114 /gdb/mi/mi-cmd-var.c | |
parent | 0092b74da6d86185c4d0c0fa0f540b97647bf44a (diff) | |
download | gdb-10f489e57677e670bf980e93896762594e9ad908.zip gdb-10f489e57677e670bf980e93896762594e9ad908.tar.gz gdb-10f489e57677e670bf980e93896762594e9ad908.tar.bz2 |
Use ui_out_emit_list
This changes some spots to use ui_out_emit_list. This only touches
"easy" cases, where the cleanup was used in a block-structured way.
There's also one more use of ui_out_emit_tuple in here.
ChangeLog
2017-04-22 Tom Tromey <tom@tromey.com>
* mi/mi-cmd-file.c (mi_cmd_file_list_shared_libraries): Use
ui_out_emit_list.
* stack.c (print_frame): Use ui_out_emit_list.
* mi/mi-symbol-cmds.c (mi_cmd_symbol_list_lines): Use
ui_out_emit_list.
* mi/mi-main.c (print_one_inferior)
(mi_cmd_data_list_register_names)
(mi_cmd_data_list_register_values, mi_cmd_list_features)
(mi_cmd_list_target_features, mi_cmd_trace_frame_collected): Use
ui_out_emit_list.
* mi/mi-interp.c (mi_on_normal_stop_1): Use ui_out_emit_list.
(mi_output_solib_attribs): Use ui_out_emit_list,
ui_out_emit_tuple.
* mi/mi-cmd-var.c (varobj_update_one): Use ui_out_emit_list.
* mi/mi-cmd-stack.c (mi_cmd_stack_list_frames)
(mi_cmd_stack_list_args, list_args_or_locals): Use
ui_out_emit_list.
* disasm.c (do_assembly_only): Use ui_out_emit_list.
* breakpoint.c (print_solib_event, output_thread_groups): Use
ui_out_emit_list.
Diffstat (limited to 'gdb/mi/mi-cmd-var.c')
-rw-r--r-- | gdb/mi/mi-cmd-var.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/gdb/mi/mi-cmd-var.c b/gdb/mi/mi-cmd-var.c index 1a7e322..191e770 100644 --- a/gdb/mi/mi-cmd-var.c +++ b/gdb/mi/mi-cmd-var.c @@ -772,16 +772,14 @@ varobj_update_one (struct varobj *var, enum print_values print_values, { int j; varobj_p child; - struct cleanup *cleanup; - cleanup = make_cleanup_ui_out_list_begin_end (uiout, "new_children"); + ui_out_emit_list list_emitter (uiout, "new_children"); for (j = 0; VEC_iterate (varobj_p, r->newobj, j, child); ++j) { ui_out_emit_tuple tuple_emitter (uiout, NULL); print_varobj (child, print_values, 1 /* print_expression */); } - do_cleanups (cleanup); VEC_free (varobj_p, r->newobj); r->newobj = NULL; /* Paranoia. */ } |