Hex number formatting

Sean Gies sean.gies@discreet.com
Tue Oct 14 23:06:00 GMT 2003


So, I've figured out how to set the default output radix so all numbers 
are displayed in hex.  Is there a similar option to cause all numbers 
to be formatted with leading zeros?  This would be very useful for 
debugging binary I/O code.

For example, if A is a 32-bit number, B is a 16-bit number and C is an 
8-bit number with values 4, 5 and 6 respectively, they would be 
displayed as follows:

	A = 0x00000004
	B = 0x0005
	C = 0x06

instead of:

	A = 0x4
	B = 0x5
	C = 0x6

Thanks,
-Sean



More information about the Gdb mailing list