aboutsummaryrefslogtreecommitdiff
path: root/gdb/doc
diff options
context:
space:
mode:
authorMarc Khouzam <marc.khouzam@ericsson.com>2008-04-09 13:29:55 +0000
committerMarc Khouzam <marc.khouzam@ericsson.com>2008-04-09 13:29:55 +0000
commitde051565dfd9173f9ca885ac8e294ae2c90e409c (patch)
tree833f79330dea8f31531d2fba050483a361efe667 /gdb/doc
parentcdb0b8f5655411f9926c49ae39386430d3df67b0 (diff)
downloadgdb-de051565dfd9173f9ca885ac8e294ae2c90e409c.zip
gdb-de051565dfd9173f9ca885ac8e294ae2c90e409c.tar.gz
gdb-de051565dfd9173f9ca885ac8e294ae2c90e409c.tar.bz2
gdb/ChangeLog
2008-04-09 Marc Khouzam <marc.khouzam@ericsson.com> * mi/mi-cmd-var.c: Include "mi-getopt.h". (mi_parse_format): New. Factored out from mi_cmd_var_set_format. (mi_cmd_var_set_format): Use new mi_parse_format. (mi_cmd_var_evaluate_expression): Support for -f option to specify format. * Makefile.in (mi-cmd-var.o): Update dependencies. * varobj.h (varobj_get_formatted_value): Declare. * varobj.c (my_value_of_variable): Added format parameter. (cplus_value_of_variable): Likewise. (java_value_of_variable): Likewise. (c_value_of_variable): Likewise. Evaluate expression based on format parameter. (struct language_specific): Add format parameter to function member *value_of_variable. (varobj_get_formatted_value): New. (varobj_get_value): Added format parameter to method call. gdb/doc/ChangeLog 2008-04-09 Marc Khouzam <marc.khouzam@ericsson.com> * gdb.texinfo (GDB/MI Variable Objects): Add anchor to -var-set-format. Add -f option to -var-evaluate-expression. gdb/testsuite/ChangeLog 2008-04-09 Marc Khouzam <marc.khouzam@ericsson.com> * gdb.mi/mi2-var-display.exp: Added tests for the new -f option of -var-evaluate-expression. * gdb.mi/mi2-var-display.exp: Likewise.
Diffstat (limited to 'gdb/doc')
-rw-r--r--gdb/doc/ChangeLog5
-rw-r--r--gdb/doc/gdb.texinfo13
2 files changed, 14 insertions, 4 deletions
diff --git a/gdb/doc/ChangeLog b/gdb/doc/ChangeLog
index 2cf219e..5e27b37 100644
--- a/gdb/doc/ChangeLog
+++ b/gdb/doc/ChangeLog
@@ -1,3 +1,8 @@
+2008-04-09 Marc Khouzam <marc.khouzam@ericsson.com>
+
+ * gdb.texinfo (GDB/MI Variable Objects): Add anchor to
+ -var-set-format. Add -f option to -var-evaluate-expression.
+
2008-04-03 Joel Brobecker <brobecker@adacore.com>
* gdb.texinfo (Breakpoint Menus): Delete. Contents moved inside
diff --git a/gdb/doc/gdb.texinfo b/gdb/doc/gdb.texinfo
index 080e42f..9355d47 100644
--- a/gdb/doc/gdb.texinfo
+++ b/gdb/doc/gdb.texinfo
@@ -20034,6 +20034,7 @@ Returns an error if the object @var{name} is not found.
Sets the output format for the value of the object @var{name} to be
@var{format-spec}.
+@anchor{-var-set-format}
The syntax for the @var{format-spec} is as follows:
@smallexample
@@ -20210,12 +20211,16 @@ where @var{attr} is @code{@{ @{ editable | noneditable @} | TBD @}}.
@subsubheading Synopsis
@smallexample
- -var-evaluate-expression @var{name}
+ -var-evaluate-expression [-f @var{format-spec}] @var{name}
@end smallexample
Evaluates the expression that is represented by the specified variable
-object and returns its value as a string. The format of the
-string can be changed using the @code{-var-set-format} command.
+object and returns its value as a string. The format of the string
+can be specified with the @samp{-f} option. The possible values of
+this option are the same as for @code{-var-set-format}
+(@pxref{-var-set-format}). If the @samp{-f} option is not specified,
+the current display format will be used. The current display format
+can be changed using the @code{-var-set-format} command.
@smallexample
value=@var{value}
@@ -20268,7 +20273,7 @@ be a root variable object. Here, ``changed'' means that the result of
object names, all existing variable objects are updated, except
for frozen ones (@pxref{-var-set-frozen}). The option
@var{print-values} determines whether both names and values, or just
-names are printed. The possible values of this options are the same
+names are printed. The possible values of this option are the same
as for @code{-var-list-children} (@pxref{-var-list-children}). It is
recommended to use the @samp{--all-values} option, to reduce the
number of MI commands needed on each program stop.