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  <tromey@adacore.com>

	PR gdb/27383:
	* parse.c (write_exp_symbol_reference): Write sym.block.
This commit is contained in:
Tom Tromey 2021-02-11 08:27:46 -07:00
parent 234b98ced2
commit b260f8d60c
2 changed files with 6 additions and 1 deletions

View File

@ -1,3 +1,8 @@
2021-02-11 Tom Tromey <tromey@adacore.com>
PR gdb/27383:
* parse.c (write_exp_symbol_reference): Write sym.block.
2021-02-11 Andrew Burgess <andrew.burgess@embecosm.com>
* NEWS: Mention changes to 'maint info sections'.

View File

@ -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);
}