I recently upgraded gdb from 7.12 to 8: 00, and debug found that when I display a string, the content displayed is very complicated! For example, startSym= "A"; such a simple string, disp startSym appears as follows:
>>> disp startSym
$2 = {
static npos = 18446744073709551615,
_M_dataplus = {
<std::allocator<char>> = {
<__gnu_cxx::new_allocator<char>> = {<No data fields>}, <No data fields>},
members of std::__cxx11::basic_string<char, std::char_traits<char>, std::allocator<char> >::_Alloc_hider:
_M_p = 0x7fffffffdd30 "A"
},
_M_string_length = 1,
{
_M_local_buf = "A\000\000\000\000\000\000\000\001\000\000\000\000\000\000",
_M_allocated_capacity = 65
}
}
I initially searched for what I thought was the set display setting, but tried many times without success. Is there any way to get back to the dry state that I used to display only the contents of strings?