Re: Consistent format for memory addresses

M.M. Kettenis
2005-05-25T05:27:29Z

Nick Roberts <nickrob@snap.net.nz> wrote:

> (gdb) info frame
> Stack level 0, frame at 0xbffff730:
> eip = 0x80484d9 in main (myprog.c:55); saved eip 0x4006015a
> ^^^^^^^^^
>
> Still seven digits. The human mind adjusts easily to such differences, but
> front ends---or at least the one I'm writing for Emacs---don't.
>
> So that I don't have to keep making piecemeal changes, I suggest that
> memory addresses in "info frame" has the same format as disassemble
> and "info break". I've not looked at the internals but maybe they could
> all be printed with the same procedure call.
>
> WDYT?

I'm all for consistency. But I think you should realize that pointers
can be 64-bit too, or even 48-bit, so your code beter not depend on a
fixed number of digits.

Cheers,

Mark