This is the mail archive of the gdb-cvs@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[binutils-gdb] Re-apply change for handling non-local references in nested functions.


https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=2d5a88dc5005a4f4b0584d02719e479645409e92

commit 2d5a88dc5005a4f4b0584d02719e479645409e92
Author: Iain Buclaw <ibuclaw@gdcproject.org>
Date:   Sun Oct 25 09:17:24 2015 +0100

    Re-apply change for handling non-local references in nested functions.
    
    gdb/ChangeLog:
    
    	* d-exp.y: Remove an obsolete comment and propagate the block
    	information to the produced expression.

Diff:
---
 gdb/ChangeLog | 5 +++++
 gdb/d-exp.y   | 4 +---
 2 files changed, 6 insertions(+), 3 deletions(-)

diff --git a/gdb/ChangeLog b/gdb/ChangeLog
index 56499c9..1afb8fd 100644
--- a/gdb/ChangeLog
+++ b/gdb/ChangeLog
@@ -1,3 +1,8 @@
+2015-10-25  Iain Buclaw  <ibuclaw@gdcproject.org>
+
+	* d-exp.y: Remove an obsolete comment and propagate the block
+	information to the produced expression.
+
 2015-10-24  Simon Marchi  <simon.marchi@polymtl.ca>
 
 	* tui/tui-data.c (tui_add_to_source_windows): Remove void *
diff --git a/gdb/d-exp.y b/gdb/d-exp.y
index 9e84a47..0481b14 100644
--- a/gdb/d-exp.y
+++ b/gdb/d-exp.y
@@ -487,9 +487,7 @@ PrimaryExpression:
 			}
 
 		      write_exp_elt_opcode (pstate, OP_VAR_VALUE);
-		      /* We want to use the selected frame, not another more inner frame
-			 which happens to be in the same block.  */
-		      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);
 		    }


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]