From 317c3ed9fc9bc5dacd267d131e8c9ca7c1cbdced Mon Sep 17 00:00:00 2001 From: Tom Tromey Date: Tue, 31 Jan 2023 13:25:17 -0700 Subject: Turn allocate_value into a static "constructor" This changes allocate_value to be a static "constructor" of value. Approved-By: Simon Marchi --- gdb/rust-lang.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'gdb/rust-lang.c') diff --git a/gdb/rust-lang.c b/gdb/rust-lang.c index 8f09536..edffad4 100644 --- a/gdb/rust-lang.c +++ b/gdb/rust-lang.c @@ -1351,7 +1351,7 @@ eval_op_rust_array (struct type *expect_type, struct expression *exp, { struct type *arraytype = lookup_array_range_type (elt->type (), 0, copies - 1); - return allocate_value (arraytype); + return value::allocate (arraytype); } } @@ -1518,7 +1518,7 @@ rust_aggregate_operation::evaluate (struct type *expect_type, } if (noside == EVAL_AVOID_SIDE_EFFECTS) - result = allocate_value (type); + result = value::allocate (type); else result = value_at_lazy (type, addr); -- cgit v1.1