From ac29888840f025448225e600d4cf99e126386878 Mon Sep 17 00:00:00 2001 From: Tom Tromey Date: Mon, 6 Jun 2016 14:18:23 -0600 Subject: Remove some variables but call functions for side effects This patch consolidates the (possibly-questionable) spots where we remove a declaration but continue to call some function for side effects. In a couple of cases it wasn't entirely clear to me that this mattered; and in some other cases it might be more aesthetically pleasing to use ATTRIBUTE_UNUSED. So, I broke this out into a separate patch for simpler review. 2016-07-14 Tom Tromey * arch-utils.c (default_skip_permanent_breakpoint): Remove "bp_insn". * disasm.c (do_assembly_only): Remove "num_displayed". * dwarf2read.c (read_abbrev_offset): Remove "length". (dwarf_decode_macro_bytes) : Remove "constant". * m32c-tdep.c (make_regs): Remove "r2hl", "r3hl", and "intbhl". * microblaze-tdep.c (microblaze_frame_cache): Remove "func". * tracefile.c (trace_save): Remove "status". --- gdb/disasm.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'gdb/disasm.c') diff --git a/gdb/disasm.c b/gdb/disasm.c index f611721..bd1f760 100644 --- a/gdb/disasm.c +++ b/gdb/disasm.c @@ -737,13 +737,11 @@ do_assembly_only (struct gdbarch *gdbarch, struct ui_out *uiout, CORE_ADDR low, CORE_ADDR high, int how_many, int flags, struct ui_file *stb) { - int num_displayed = 0; struct cleanup *ui_out_chain; ui_out_chain = make_cleanup_ui_out_list_begin_end (uiout, "asm_insns"); - num_displayed = dump_insns (gdbarch, uiout, di, low, high, how_many, - flags, stb, NULL); + dump_insns (gdbarch, uiout, di, low, high, how_many, flags, stb, NULL); do_cleanups (ui_out_chain); } -- cgit v1.1