From 8f04399994587ef7931511d18d72526de3f6f2b3 Mon Sep 17 00:00:00 2001 From: Jan Kratochvil Date: Mon, 16 Jul 2012 19:15:39 +0000 Subject: gdb/ PR 11914 * f-valprint.c (info_common_command): New variable frame_id. Reinitialize FI form FRAME_ID after each print_variable_and_value. * printcmd.c (print_variable_and_value): Extend function comment. Add comment for invalidated FRAME. * stack.c (backtrace_command_1): New variable frame_id. Reinitialize FI form FRAME_ID after each print_frame_local_vars. (struct print_variable_and_value_data): Change frame to frame_id. (do_print_variable_and_value): New variable frame, initialize it from p->frame_id. Add comment for invalidated FRAME. (print_frame_local_vars, print_frame_arg_vars): New function comment. Update CB_DATA.FRAME to CB_DATA.FRAME_ID initialization. Add comment for invalidated FRAME. gdb/testsuite/ PR 11914 * gdb.python/py-prettyprint.c (eval_func, eval_sub): New. (main): Call eval_sub. * gdb.python/py-prettyprint.exp: (python execfile ('py-prettyprint.py')): Move it earlier. New breakpoint for eval-break. (continue to breakpoint: eval-break, info locals): New test. (python execfile ('py-prettyprint.py')): Move it from here. * gdb.python/py-prettyprint.py (class pp_eval_type): New. (register_pretty_printers): Register pp_eval_type. --- gdb/testsuite/gdb.python/py-prettyprint.exp | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) (limited to 'gdb/testsuite/gdb.python/py-prettyprint.exp') diff --git a/gdb/testsuite/gdb.python/py-prettyprint.exp b/gdb/testsuite/gdb.python/py-prettyprint.exp index a6c241a..22af83c 100644 --- a/gdb/testsuite/gdb.python/py-prettyprint.exp +++ b/gdb/testsuite/gdb.python/py-prettyprint.exp @@ -123,14 +123,19 @@ if ![runto_main ] then { return } -gdb_test "b [gdb_get_line_number {break to inspect} ${testfile}.c ]" \ - ".*Breakpoint.*" -gdb_test "continue" ".*Breakpoint.*" - set remote_python_file [remote_download host ${srcdir}/${subdir}/${testfile}.py] gdb_test_no_output "python execfile ('${remote_python_file}')" +gdb_breakpoint [gdb_get_line_number "eval-break"] +gdb_continue_to_breakpoint "eval-break" ".* eval-break .*" + +gdb_test "info locals" "eval9 = eval=<123456789>" + +gdb_test "b [gdb_get_line_number {break to inspect} ${testfile}.c ]" \ + ".*Breakpoint.*" +gdb_test "continue" ".*Breakpoint.*" + gdb_test "print ss" " = a=< a=<1> b=<$hex>> b=< a=<2> b=<$hex>>" \ "print ss enabled #1" -- cgit v1.1