mirror of
https://github.com/darlinghq/darling-gdb.git
synced 2024-12-12 14:37:43 +00:00
gdb/
* valops.c (value_repeat): Use read_value_memory instead of read_memory. gdb/testsuite/ * gdb.trace/unavailable.exp (gdb_collect_globals_test): Test that value repeat handles unavailableness.
This commit is contained in:
parent
39d3738556
commit
24e6bceefb
@ -1,3 +1,8 @@
|
||||
2011-02-14 Pedro Alves <pedro@codesourcery.com>
|
||||
|
||||
* valops.c (value_repeat): Use read_value_memory instead of
|
||||
read_memory.
|
||||
|
||||
2011-02-14 Pedro Alves <pedro@codesourcery.com>
|
||||
|
||||
* value.h (value_contents_copy, value_contents_copy_raw): Declare.
|
||||
|
@ -1,3 +1,8 @@
|
||||
2011-02-14 Pedro Alves <pedro@codesourcery.com>
|
||||
|
||||
* gdb.trace/unavailable.exp (gdb_collect_globals_test): Test that
|
||||
value repeat handles unavailableness.
|
||||
|
||||
2011-02-14 Pedro Alves <pedro@codesourcery.com>
|
||||
|
||||
* gdb.trace/unavailable.exp (gdb_collect_globals_test): Add new
|
||||
|
@ -155,6 +155,9 @@ proc gdb_collect_globals_test { } {
|
||||
|
||||
gdb_test_no_output "set print repeat 10"
|
||||
|
||||
# Check that value repeat handles unavailable-ness.
|
||||
gdb_test "print *tarray@3" " = \\{\\{a = 0, b = <unavailable>\\}, \\{a = 0, b = <unavailable>\\}, \\{a = <unavailable>, b = <unavailable>\\}\\}"
|
||||
|
||||
# Static fields
|
||||
|
||||
gdb_test "print struct_b.static_struct_a" \
|
||||
|
@ -1456,12 +1456,13 @@ value_repeat (struct value *arg1, int count)
|
||||
|
||||
val = allocate_repeat_value (value_enclosing_type (arg1), count);
|
||||
|
||||
read_memory (value_address (arg1),
|
||||
value_contents_all_raw (val),
|
||||
TYPE_LENGTH (value_enclosing_type (val)));
|
||||
VALUE_LVAL (val) = lval_memory;
|
||||
set_value_address (val, value_address (arg1));
|
||||
|
||||
read_value_memory (val, 0, value_stack (val), value_address (val),
|
||||
value_contents_all_raw (val),
|
||||
TYPE_LENGTH (value_enclosing_type (val)));
|
||||
|
||||
return val;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user