From b260f8d60c24fb541b9b4635ed31e30e6acd6b7a Mon Sep 17 00:00:00 2001 From: Tom Tromey Date: Thu, 11 Feb 2021 08:27:46 -0700 Subject: [PATCH] Fix two Fortran regressions Luis pointed out that an earlier patch of mine caused two regressions in gdb.fortran. This patch fixes the problem. Regression tested on x86-64 Fedora 32. gdb/ChangeLog 2021-02-11 Tom Tromey PR gdb/27383: * parse.c (write_exp_symbol_reference): Write sym.block. --- gdb/ChangeLog | 5 +++++ gdb/parse.c | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/gdb/ChangeLog b/gdb/ChangeLog index 10f391e5ea5..4d0033de625 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,8 @@ +2021-02-11 Tom Tromey + + PR gdb/27383: + * parse.c (write_exp_symbol_reference): Write sym.block. + 2021-02-11 Andrew Burgess * NEWS: Mention changes to 'maint info sections'. diff --git a/gdb/parse.c b/gdb/parse.c index d634a4f736c..884a00862ec 100644 --- a/gdb/parse.c +++ b/gdb/parse.c @@ -661,7 +661,7 @@ write_exp_symbol_reference (struct parser_state *pstate, const char *name, if (symbol_read_needs_frame (sym.symbol)) pstate->block_tracker->update (sym); write_exp_elt_opcode (pstate, OP_VAR_VALUE); - write_exp_elt_block (pstate, NULL); + write_exp_elt_block (pstate, sym.block); write_exp_elt_sym (pstate, sym.symbol); write_exp_elt_opcode (pstate, OP_VAR_VALUE); } -- 2.30.2