From f976f6d464baa59f8d890626648c74943aed1ce1 Mon Sep 17 00:00:00 2001 From: Andrew Cagney Date: Tue, 25 Dec 2001 22:24:39 +0000 Subject: * cli/cli-script.c (execute_control_command): Replace value_ptr with a struct value pointer. * ch-lang.c (evaluate_subexp_chill): Ditto. * printcmd.c (printf_command): Ditto. * tracepoint.c (set_traceframe_context): Ditto. (encode_actions): Ditto. * eval.c (evaluate_subexp_standard): Ditto. --- gdb/ChangeLog | 10 ++++++++++ gdb/ch-lang.c | 3 ++- gdb/cli/cli-script.c | 4 ++-- gdb/eval.c | 6 +++--- gdb/printcmd.c | 9 +++++---- gdb/tracepoint.c | 5 +++-- 6 files changed, 25 insertions(+), 12 deletions(-) (limited to 'gdb') diff --git a/gdb/ChangeLog b/gdb/ChangeLog index d4f5a0a..5e7a6e6 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,5 +1,15 @@ 2001-12-25 Andrew Cagney + * cli/cli-script.c (execute_control_command): Replace value_ptr + with a struct value pointer. + * ch-lang.c (evaluate_subexp_chill): Ditto. + * printcmd.c (printf_command): Ditto. + * tracepoint.c (set_traceframe_context): Ditto. + (encode_actions): Ditto. + * eval.c (evaluate_subexp_standard): Ditto. + +2001-12-25 Andrew Cagney + * gdbarch.sh: When an int variable, print value using %d instead of %ld. * gdbarch.c: Re-generate. diff --git a/gdb/ch-lang.c b/gdb/ch-lang.c index ec3a76e..f65e635 100644 --- a/gdb/ch-lang.c +++ b/gdb/ch-lang.c @@ -536,7 +536,8 @@ evaluate_subexp_chill (struct type *expect_type, /* Allocate arg vector, including space for the function to be called in argvec[0] and a terminating NULL */ - argvec = (value_ptr *) alloca (sizeof (value_ptr) * (nargs + 2)); + argvec = (struct value **) alloca (sizeof (struct value *) + * (nargs + 2)); argvec[0] = arg1; tem = 1; for (; tem <= nargs && tem <= TYPE_NFIELDS (type); tem++) diff --git a/gdb/cli/cli-script.c b/gdb/cli/cli-script.c index 3fb49f1..feec17f 100644 --- a/gdb/cli/cli-script.c +++ b/gdb/cli/cli-script.c @@ -332,8 +332,8 @@ execute_control_command (struct command_line *cmd) struct expression *expr; struct command_line *current; struct cleanup *old_chain = 0; - value_ptr val; - value_ptr val_mark; + struct value *val; + struct value *val_mark; int loop; enum command_control_type ret; char *new_line; diff --git a/gdb/eval.c b/gdb/eval.c index 8a41d30..a56ed84 100644 --- a/gdb/eval.c +++ b/gdb/eval.c @@ -620,7 +620,7 @@ evaluate_subexp_standard (struct type *expect_type, return set; } - argvec = (value_ptr *) alloca (sizeof (value_ptr) * nargs); + argvec = (struct value **) alloca (sizeof (struct value *) * nargs); for (tem = 0; tem < nargs; tem++) { /* Ensure that array expressions are coerced into pointer objects. */ @@ -673,7 +673,7 @@ evaluate_subexp_standard (struct type *expect_type, nargs = longest_to_int (exp->elts[pc + 1].longconst); /* Allocate arg vector, including space for the function to be called in argvec[0] and a terminating NULL */ - argvec = (value_ptr *) alloca (sizeof (value_ptr) * (nargs + 3)); + argvec = (struct value **) alloca (sizeof (struct value *) * (nargs + 3)); if (op == STRUCTOP_MEMBER || op == STRUCTOP_MPTR) { LONGEST fnptr; @@ -969,7 +969,7 @@ evaluate_subexp_standard (struct type *expect_type, /* It's a function call. */ /* Allocate arg vector, including space for the function to be called in argvec[0] and a terminating NULL */ - argvec = (value_ptr *) alloca (sizeof (value_ptr) * (nargs + 2)); + argvec = (struct value **) alloca (sizeof (struct value *) * (nargs + 2)); argvec[0] = arg1; tem = 1; for (; tem <= nargs; tem++) diff --git a/gdb/printcmd.c b/gdb/printcmd.c index bb02d8d..9db1547 100644 --- a/gdb/printcmd.c +++ b/gdb/printcmd.c @@ -2045,7 +2045,8 @@ printf_command (char *arg, int from_tty) int allocated_args = 20; struct cleanup *old_cleanups; - val_args = (value_ptr *) xmalloc (allocated_args * sizeof (value_ptr)); + val_args = (struct value **) xmalloc (allocated_args + * sizeof (struct value *)); old_cleanups = make_cleanup (free_current_contents, &val_args); if (s == 0) @@ -2209,9 +2210,9 @@ printf_command (char *arg, int from_tty) { char *s1; if (nargs == allocated_args) - val_args = (value_ptr *) xrealloc ((char *) val_args, - (allocated_args *= 2) - * sizeof (value_ptr)); + val_args = (struct value **) xrealloc ((char *) val_args, + (allocated_args *= 2) + * sizeof (struct value *)); s1 = s; val_args[nargs] = parse_to_comma_and_eval (&s1); diff --git a/gdb/tracepoint.c b/gdb/tracepoint.c index 45794e6..7e2f112 100644 --- a/gdb/tracepoint.c +++ b/gdb/tracepoint.c @@ -254,7 +254,8 @@ set_traceframe_context (CORE_ADDR trace_pc) { static struct type *func_string, *file_string; static struct type *func_range, *file_range; - static value_ptr func_val, file_val; + struct value *func_val; + struct value *file_val; static struct type *charstar; int len; @@ -1486,7 +1487,7 @@ encode_actions (struct tracepoint *t, char ***tdp_actions, struct expression *exp = NULL; struct action_line *action; int i; - value_ptr tempval; + struct value *tempval; struct collection_list *collect; struct cmd_list_element *cmd; struct agent_expr *aexpr; -- cgit v1.1