* Display content of unicode std::wstring objects
@ 2008-08-15 18:26 Fredrik Orderud
2008-08-15 20:04 ` Paul Pluzhnikov
0 siblings, 1 reply; 2+ messages in thread
From: Fredrik Orderud @ 2008-08-15 18:26 UTC (permalink / raw)
To: gdb
Is there any in-build support for displaying the content of C++ STL unicode
text-strings in gdb?
In my C++ program I have a lot of std::wstring objects, and I want a
convenient way to display the content of these unicode strings from gdb
whenever I break my program. Currently, I just dump the content of the
memory area manually with "x/20c str_obj._M_dataplus._M_p" (for a
"std::wstring str_obj" object), but this is inconvenient due to the
"_M_dataplus._M_p" subfields and results in a very verbose listing. You also
need to know the string length in advance with this approach.
On my machine I run Fedora linux 9, with gcc/g++ 4.3.0 and gdb 6.8.
Thanks in advance
Fredrik Orderud
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2008-08-15 15:02 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2008-08-15 18:26 Display content of unicode std::wstring objects Fredrik Orderud
2008-08-15 20:04 ` Paul Pluzhnikov
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox