gdb调试技巧.gdbinit

465 阅读1分钟

找到一篇gdb调试STL,解引用容器的.gdbinit配置。

www.yolinux.com/TUTORIALS/G…

放到了码云的代码片段里了。

适合GDB 4.3+。

Data typeGDB command
std::vectorpvector stl_variable
std::listplist stl_variable T
std::map<T,T>pmap stl_variable
std::multimap<T,T>pmap stl_variable
std::setpset stl_variable T
std::multisetpset stl_variable
std::dequepdequeue stl_variable
std::stackpstack stl_variable
std::queuepqueue stl_variable
std::priority_queueppqueue stl_variable
std::bitsettd>pbitset stl_variable
std::stringpstring stl_variable
std::widestringpwstring stl_variable