Does anyone know how to debug objects of the type stream in general
using GDB ? I am currently using GDB version 6.4.
There is no much usefull information about it througout the internet.
I am using the tips of the sites below to debug STL containers but I
found nothing about stream.
http://www.yolinux.com/TUTORIALS/GDB....html#STLDEREF
Basically I need to see the contents on a stringstream as the one on
the program below, but I can not use call either print on a
stringstream object.
#include <iostream>
#include <sstream>
using namespace std;
int main ( int argc, char* argv[] ) {
cout << "Starting Processing" << endl;
stringstream l_Str;
l_Str << "foo";
cout << "Process finished" << endl;
return 0;
}
g++ -ggdb -o test test.cpp
gdb ./test
(gdb) break test.cpp:12
(gdb) run
(gdb) call l_Str.str()
Couldn't find method stringstream::str
(gdb) print l_Str.str()
Couldn't find method stringstream::str
(gdb) print l_Str
$1 = <incomplete type>