xcode LLDB 相当于 Xcode4.1 中 GDB 中的`po`?

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/6804447/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-09-14 21:33:18  来源:igfitidea点击:

LLDB equivalent of `po` in GDB in Xcode4.1?

objective-cxcodedebugginggdblldb

提问by Eonil

There is a command poin GDB which prints Objective-C object details. (with its description) In LLDB, pojust print memory address. How can I see similar output of GDB in LLDB?

poGDB 中有一个命令可以打印 Objective-C 对象的详细信息。(及其描述)在 LLDB 中,po只需打印内存地址。如何在 LLDB 中看到类似的 GDB 输出?

回答by Victor Jalencas

It is implemented nowadays. For completeness sake, it is an alias to this command:

它在今天实施。为了完整起见,它是此命令的别名:

expression -o  --

For help with this and other LLDB commands, use the command help:

有关此命令和其他 LLDB 命令的帮助,请使用命令帮助:

help expression

回答by Vincent Gable

Here are some handy GDB to LLDB command equivalents.

这里有一些方便的GDB 到 LLDB 命令的等价物

回答by Eonil

It looks like not implemented yet at this time. http://lldb.llvm.org/status.html

目前看来还没有实现。http://lldb.llvm.org/status.html

回答by matt

Don't know lldb, but maybe something to the effect of:

不知道 lldb,但可能有以下影响:

print _NSPrintForDebugger(obj)