public inbox for gdb-prs@sourceware.org
help / color / mirror / Atom feed
* [Bug exp/9128] Add option to display leading zeros on hexidecimal output
       [not found] <20051101195801.9128.seangies@apple.com>
@ 2009-01-18 18:55 ` pedro at codesourcery dot com
  0 siblings, 0 replies; 2+ messages in thread
From: pedro at codesourcery dot com @ 2009-01-18 18:55 UTC (permalink / raw)
  To: gdb-prs



-- 
           What    |Removed                     |Added
----------------------------------------------------------------------------
          Component|tui                         |exp


http://sourceware.org/bugzilla/show_bug.cgi?id=9128

------- You are receiving this mail because: -------
You are on the CC list for the bug, or are watching someone who is.


^ permalink raw reply	[flat|nested] 2+ messages in thread

* [Bug exp/9128] Add option to display leading zeros on hexidecimal output
       [not found] <bug-9128-4717@http.sourceware.org/bugzilla/>
@ 2020-04-29 14:29 ` ssbssa at sourceware dot org
  0 siblings, 0 replies; 2+ messages in thread
From: ssbssa at sourceware dot org @ 2020-04-29 14:29 UTC (permalink / raw)
  To: gdb-prs

https://sourceware.org/bugzilla/show_bug.cgi?id=9128

Hannes Domani <ssbssa at sourceware dot org> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |ssbssa at sourceware dot org

--- Comment #1 from Hannes Domani <ssbssa at sourceware dot org> ---
The print command accepts the 'z' format letter, which zero-padds the hex
numbers.

(gdb) p hex
$6 = {
  i8 = 4 '\004',
  i16 = 5,
  i32 = 6,
  i64 = 7
}
(gdb) p/x hex
$7 = {
  i8 = 0x4,
  i16 = 0x5,
  i32 = 0x6,
  i64 = 0x7
}
(gdb) p/z hex
$8 = {
  i8 = 0x04,
  i16 = 0x0005,
  i32 = 0x00000006,
  i64 = 0x0000000000000007
}

But it can't be used for info locals, so it's probably not enough to close this
PR.

-- 
You are receiving this mail because:
You are on the CC list for the bug.

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2020-04-29 14:29 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
     [not found] <20051101195801.9128.seangies@apple.com>
2009-01-18 18:55 ` [Bug exp/9128] Add option to display leading zeros on hexidecimal output pedro at codesourcery dot com
     [not found] <bug-9128-4717@http.sourceware.org/bugzilla/>
2020-04-29 14:29 ` ssbssa at sourceware dot org

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).