From 65d3800afdbb924961d55980838aafe9c84962e6 Mon Sep 17 00:00:00 2001 From: Daniel Jacobowitz Date: Sun, 21 Nov 2004 19:52:13 +0000 Subject: [PATCH] * valarith.c (value_subscript): Copy VALUE_FRAME_ID. (value_subscripted_rvalue): Likewise. * valops.c (search_struct_field, value_slice): Likewise. --- gdb/ChangeLog | 6 ++++++ gdb/valarith.c | 2 ++ gdb/valops.c | 2 ++ 3 files changed, 10 insertions(+) diff --git a/gdb/ChangeLog b/gdb/ChangeLog index 1a525bc96cb..834ed23377f 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,9 @@ +2004-11-21 Daniel Jacobowitz + + * valarith.c (value_subscript): Copy VALUE_FRAME_ID. + (value_subscripted_rvalue): Likewise. + * valops.c (search_struct_field, value_slice): Likewise. + 2004-11-21 Mark Kettenis * inf-ptrace.c: Don't include "regcache.h" and "gdbcmd.h". diff --git a/gdb/valarith.c b/gdb/valarith.c index ea93ea11111..00f20e16c41 100644 --- a/gdb/valarith.c +++ b/gdb/valarith.c @@ -239,6 +239,7 @@ value_subscript (struct value *array, struct value *idx) if (VALUE_LVAL (array) == lval_internalvar) VALUE_LVAL (v) = lval_internalvar_component; VALUE_ADDRESS (v) = VALUE_ADDRESS (array); + VALUE_FRAME_ID (v) = VALUE_FRAME_ID (array); v->offset = offset + value_offset (array); return v; } @@ -278,6 +279,7 @@ value_subscripted_rvalue (struct value *array, struct value *idx, int lowerbound VALUE_LVAL (v) = VALUE_LVAL (array); VALUE_ADDRESS (v) = VALUE_ADDRESS (array); VALUE_REGNUM (v) = VALUE_REGNUM (array); + VALUE_FRAME_ID (v) = VALUE_FRAME_ID (array); v->offset = value_offset (array) + elt_offs; return v; } diff --git a/gdb/valops.c b/gdb/valops.c index fa63871a532..c708fac590a 100644 --- a/gdb/valops.c +++ b/gdb/valops.c @@ -1307,6 +1307,7 @@ search_struct_field (char *name, struct value *arg1, int offset, { VALUE_LVAL (v2) = VALUE_LVAL (arg1); VALUE_ADDRESS (v2) = VALUE_ADDRESS (arg1); + VALUE_FRAME_ID (v2) = VALUE_FRAME_ID (arg1); v2->offset = value_offset (arg1) + boffset; if (VALUE_LAZY (arg1)) VALUE_LAZY (v2) = 1; @@ -2768,6 +2769,7 @@ value_slice (struct value *array, int lowbound, int length) else VALUE_LVAL (slice) = VALUE_LVAL (array); VALUE_ADDRESS (slice) = VALUE_ADDRESS (array); + VALUE_FRAME_ID (slice) = VALUE_FRAME_ID (array); slice->offset = value_offset (array) + offset; } return slice; -- 2.30.2