diff mbox

[v2,3/3] Documentation changes for the new zero-hexadecimal format

Message ID 1431020207-14371-4-git-send-email-lgustavo@codesourcery.com
State New
Headers show

Commit Message

Luis Machado May 7, 2015, 5:36 p.m. UTC
This patch updates the documentation to reflect the addition of the new
zero-hexadecimal format option for -var-set-format and also adds a NEWS entry
for the change.

I changed it from zhexadecimal to zero-hexadecimal so the IDE folks can
properly translate the string to something more reasonable.

gdb/ChangeLog:

2015-05-07  Luis Machado  <lgustavo@codesourcery.com>

	* NEWS: Add new note to MI changes.

gdb/doc/ChangeLog:

2015-05-07  Luis Machado  <lgustavo@codesourcery.com>

	* gdb.texinfo (GDB/MI Variable Objects): Update text for
	-var-set-format.
---
 gdb/NEWS            | 6 ++++++
 gdb/doc/gdb.texinfo | 7 ++++++-
 2 files changed, 12 insertions(+), 1 deletion(-)

Comments

Eli Zaretskii May 7, 2015, 6:01 p.m. UTC | #1
> From: Luis Machado <lgustavo@codesourcery.com>
> Date: Thu, 7 May 2015 14:36:47 -0300
> 
> This patch updates the documentation to reflect the addition of the new
> zero-hexadecimal format option for -var-set-format and also adds a NEWS entry
> for the change.
> 
> I changed it from zhexadecimal to zero-hexadecimal so the IDE folks can
> properly translate the string to something more reasonable.

This is OK, but please make the ChangeLog entries more
self-explanatory.  Right now, they are not really informative:

	* NEWS: Add new note to MI changes.
	* gdb.texinfo (GDB/MI Variable Objects): Update text for
	-var-set-format.

They should mention "zero-hexadecimal", at the least.
diff mbox

Patch

diff --git a/gdb/NEWS b/gdb/NEWS
index 0c7084a..69a8f19 100644
--- a/gdb/NEWS
+++ b/gdb/NEWS
@@ -145,6 +145,12 @@  qXfer:exec-file:read
 HP/PA running HP-UX           hppa*-*-hpux*
 Itanium running HP-UX         ia64-*-hpux*
 
+* MI changes
+
+  ** The -var-set-format command now accepts the zero-hexadecimal
+     format.  It outputs data in hexadecimal format with zero-padding on the
+     left.
+
 *** Changes in GDB 7.9
 
 * GDB now supports hardware watchpoints on x86 GNU Hurd.
diff --git a/gdb/doc/gdb.texinfo b/gdb/doc/gdb.texinfo
index 19d8bb3..ef0be3c 100644
--- a/gdb/doc/gdb.texinfo
+++ b/gdb/doc/gdb.texinfo
@@ -28927,13 +28927,18 @@  The syntax for the @var{format-spec} is as follows:
 
 @smallexample
  @var{format-spec} @expansion{}
- @{binary | decimal | hexadecimal | octal | natural@}
+ @{binary | decimal | hexadecimal | octal | natural | zero-hexadecimal@}
 @end smallexample
 
 The natural format is the default format choosen automatically
 based on the variable type (like decimal for an @code{int}, hex
 for pointers, etc.).
 
+The zero-hexadecimal format has a representation similar to hexadecimal
+but with padding zeroes to the left of the value.  For example, a 32-bit
+hexadecimal value of 0x1234 would be represented as 0x00001234 in the
+zero-hexadecimal format.
+ 
 For a variable with children, the format is set only on the 
 variable itself, and the children are not affected.