aboutsummaryrefslogtreecommitdiff
path: root/gdb/doc/gdb.texinfo
diff options
context:
space:
mode:
authorJan Kratochvil <jan.kratochvil@redhat.com>2011-10-09 19:41:17 +0000
committerJan Kratochvil <jan.kratochvil@redhat.com>2011-10-09 19:41:17 +0000
commit36b11add17bf287b541a107ee64f7e313e77092f (patch)
tree10896f0386763977ee0ed611c252dac694387d88 /gdb/doc/gdb.texinfo
parent3343315ba7c882c948decb9aaad83e4c048a4527 (diff)
downloadgdb-36b11add17bf287b541a107ee64f7e313e77092f.zip
gdb-36b11add17bf287b541a107ee64f7e313e77092f.tar.gz
gdb-36b11add17bf287b541a107ee64f7e313e77092f.tar.bz2
gdb/
Support @entry in input expressions. * c-exp.y (ENTRY, unknown_cpp_name): New. (exp: UNKNOWN_CPP_NAME): Change to `exp: unknown_cpp_name'. (unknown_cpp_name: UNKNOWN_CPP_NAME, unknown_cpp_name: ENTRY) (variable: name_not_typename '@' ENTRY, name: ENTRY) (name_not_typename: ENTRY): New. (yylex): Recognize ENTRY. * eval.c (evaluate_subexp_standard): Support also OP_VAR_ENTRY_VALUE. * expprint.c (print_subexp_standard, dump_subexp_body_standard): Likewise. * parse.c (operator_length_standard): Likewise. * std-operator.def: New operator OP_VAR_ENTRY_VALUE. gdb/doc/ Support @entry in input expressions. * gdb.texinfo (Variables): Describe @entry names suffix. (Print Settings): Add anchor for `set print entry-values'. gdb/testsuite/ Support @entry in input expressions. * gdb.arch/amd64-entry-value.exp (entry: p i@entry, entry: p j@entry) (entry_stack: p s1@entry, entry_stack: p s2@entry) (entry_stack: p d9@entry, entry_stack: p da@entry, tailcall: p i@entry) (tailcall: p j@entry): New tests. * gdb.cp/koenig.cc (A::entry): New function. (main): Call it. * gdb.cp/koenig.exp (p entry (c)): New test.
Diffstat (limited to 'gdb/doc/gdb.texinfo')
-rw-r--r--gdb/doc/gdb.texinfo18
1 files changed, 18 insertions, 0 deletions
diff --git a/gdb/doc/gdb.texinfo b/gdb/doc/gdb.texinfo
index 9de96c1..1ea2ba3 100644
--- a/gdb/doc/gdb.texinfo
+++ b/gdb/doc/gdb.texinfo
@@ -7277,6 +7277,23 @@ If you ask to print an object whose contents are unknown to
by the debug information, @value{GDBN} will say @samp{<incomplete
type>}. @xref{Symbols, incomplete type}, for more about this.
+If you append @kbd{@@entry} string to a function parameter name you get its
+value at the time the function got called. If the value is not available an
+error message is printed. Entry values are available only with some compilers.
+Entry values are normally also printed at the function parameter list according
+to @ref{set print entry-values}.
+
+@smallexample
+Breakpoint 1, d (i=30) at gdb.base/entry-value.c:29
+29 i++;
+(gdb) next
+30 e (i);
+(gdb) print i
+$1 = 31
+(gdb) print i@@entry
+$2 = 30
+@end smallexample
+
Strings are identified as arrays of @code{char} values without specified
signedness. Arrays of either @code{signed char} or @code{unsigned char} get
printed as arrays of 1 byte sized integers. @code{-fsigned-char} or
@@ -7941,6 +7958,7 @@ thus speeding up the display of each Ada frame.
@item show print frame-arguments
Show how the value of arguments should be displayed when printing a frame.
+@anchor{set print entry-values}
@item set print entry-values @var{value}
@kindex set print entry-values
Set printing of frame argument values at function entry. In some cases