This is the mail archive of the
mailing list for the GDB project.
Re: printing wchar_t*
> From: Vladimir Prus <email@example.com>
> Date: Mon, 17 Apr 2006 16:16:26 +0400
> Cc: firstname.lastname@example.org,
> Eli, I think we're running in circles.
Fine, then I'll just stop responding. This is my last (and hopefully
short) contribution to this thread.
> 1. For any wchar_t* value, be it value of a variable, or function
> parameter three levels up the stack, or member of structure, I want
> gdb to print that value in specific format that's easy for frontend
> to use. String with escapes is fine.
A noble goal. If you (or someone else) submits patches, I'll be happy
to review them.
> 2. I want that formatting to take effect both for MI commands and for
> 'print' command, since the user can issue 'print' command manually.
I think CLI and MI are two different cases, and thus simple solutions
that are appropriate for MI (because it doesn't display) will not be
good enough for CLI.
> 3. I don't mind having this behaviour only when --interpreter=mi is
I don't think `print' should behave differently depending on the
interpreter, but whatever.
> First you say it's not possible to detect encoding from environment. Then you
> say you can't trust user/frontend. Together, that sounds like the problem of
> making gdb print char* literals reliably is impossible. Is that what you're
> trying to say?
I'm trying to say that it would be absurd to add all that complexity