diff options
author | Daniel Jacobowitz <drow@false.org> | 2007-02-27 19:46:04 +0000 |
---|---|---|
committer | Daniel Jacobowitz <drow@false.org> | 2007-02-27 19:46:04 +0000 |
commit | 206415a3eac4f69d24cf872f880f554d3d43f1bb (patch) | |
tree | ad72202befac2e3d20e6769060ab6c0c6384d824 /gdb/valops.c | |
parent | e1c9b6f16a257b4ffff961d59fc9204847eca1f4 (diff) | |
download | fsf-binutils-gdb-206415a3eac4f69d24cf872f880f554d3d43f1bb.zip fsf-binutils-gdb-206415a3eac4f69d24cf872f880f554d3d43f1bb.tar.gz fsf-binutils-gdb-206415a3eac4f69d24cf872f880f554d3d43f1bb.tar.bz2 |
* frame.c (deprecated_selected_frame): Rename to...
(selected_frame): ...this. Make static.
(get_selected_frame, select_frame): Update.
* frame.h (deprected_select_frame): Delete.
(deprecated_safe_get_selected_frame): Update comments.
* breakpoint.c, cli/cli-cmds.c, f-valprint.c, infcmd.c, inflow.c,
infrun.c, stack.c, tui/tui-disasm.c, tui/tui-source.c,
tui/tui-winsource.c, valops.c, varobj.c, findvar.c, macroscope.c,
parse.c, regcache.h, sh64-tdep.c, tui/tui-hooks.c, tui/tui-win.c,
tui/tui.c: Replace references to deprecated_selected_frame.
Diffstat (limited to 'gdb/valops.c')
-rw-r--r-- | gdb/valops.c | 16 |
1 files changed, 9 insertions, 7 deletions
diff --git a/gdb/valops.c b/gdb/valops.c index 51304be..d7ecb2a 100644 --- a/gdb/valops.c +++ b/gdb/valops.c @@ -578,7 +578,7 @@ value_assign (struct value *toval, struct value *fromval) /* Since modifying a register can trash the frame chain, and modifying memory can trash the frame cache, we save the old frame and then restore the new frame afterwards. */ - old_frame = get_frame_id (deprecated_selected_frame); + old_frame = get_frame_id (deprecated_safe_get_selected_frame ()); switch (VALUE_LVAL (toval)) { @@ -2667,16 +2667,18 @@ value_of_local (const char *name, int complain) struct symbol *func, *sym; struct block *b; struct value * ret; + struct frame_info *frame; - if (deprecated_selected_frame == 0) + if (complain) + frame = get_selected_frame (_("no frame selected")); + else { - if (complain) - error (_("no frame selected")); - else + frame = deprecated_safe_get_selected_frame (); + if (frame == 0) return 0; } - func = get_frame_function (deprecated_selected_frame); + func = get_frame_function (frame); if (!func) { if (complain) @@ -2705,7 +2707,7 @@ value_of_local (const char *name, int complain) return NULL; } - ret = read_var_value (sym, deprecated_selected_frame); + ret = read_var_value (sym, frame); if (ret == 0 && complain) error (_("`%s' argument unreadable"), name); return ret; |