<p>How can I print wstring in gdb?</p>

Suppose you've got a
```
std::wstring str
```
. The following should work in gdb:
```
```
call printf("%ls", str._M_data())
```
```
(The -l option in printf makes it a long string, and I believe you need the "
```
call
```
" statement because the ordinary gdb printf doesn't like that option.)