返回信息流和java的PrintStackTrace类似的效果
这是一条镜像帖。来源:北邮人论坛 / cpp / #99353同步于 2019/8/12
该镜像源已超过 30 天没有更新,可能在源站已被删除。
CPP机器人发帖
C++有什么在Linux系统下打印函数调用栈对应的源代码文件和行号
xfcy0718
2019/8/12镜像同步9 回复
订阅后,新回复会通过你的通知中心匿名送达。
9 条回复
https://stackoverflow.com/questions/4636456/how-to-get-a-stack-trace-for-c-using-gcc-with-line-number-information
如果是ELF格式可以看看这个 https://github.com/yandex/ClickHouse/blob/master/dbms/src/Common/SymbolIndex.cpp#L33
多谢
【 在 maweihu 的大作中提到: 】
: 如果是ELF格式可以看看这个 https://github.com/yandex/ClickHouse/blob/master/dbms/src/Common/SymbolIndex.cpp#L33
很棒
【 在 Name1e5s 的大作中提到: 】
: https://stackoverflow.com/questions/4636456/how-to-get-a-stack-trace-for-c-using-gcc-with-line-number-information