简体   繁体   English

lldb - 无法为 Objective-C 静态方法调用解析类

[英]lldb - Couldn't resolve the class for an Objective-C static method call

What's wrong with lldb? lldb 有什么问题? Was doing it many times but now does not work.做了很多次,但现在不起作用。 (Xcode 6.4 and Xcode 7.0-beta) (Xcode 6.4 和 Xcode 7.0-beta)

(lldb) po [UIApplication sharedApplication]
Error [IRForTarget]: Couldn't resolve the class for an Objective-C static method call
error: 0 errors parsing expression
error: The expression could not be prepared to run in the target

(lldb) p @[@"", @""]
Error [IRForTarget]: Couldn't resolve the class for an Objective-C static method call
error: 0 errors parsing expression
error: The expression could not be prepared to run in the target

(lldb) po @[@"", @""]
Error [IRForTarget]: Couldn't resolve the class for an Objective-C static method call
error: 0 errors parsing expression
error: The expression could not be prepared to run in the target

(lldb) e id $a = @[@"11"]
Error [IRForTarget]: Couldn't resolve the class for an Objective-C static method call
error: 0 errors parsing expression
error: The expression could not be prepared to run in the target

update更新

Maybe it was a problem with my iPod touch on ios 9.0 beta but on mine colleague's iPad with ios 8.4 all work well.也许这是我的 iPod touch 在 ios 9.0 beta 上的问题,但在我同事的 iPad 上,ios 8.4 一切正常。 The problem has been solved.问题已经解决。

I find Xcode settting:Targets->build Settings->Mach-O Type, change Dynamic Library to Static Library.我找到 Xcode 设置:目标-> 构建设置-> Mach-O 类型,将动态库更改为静态库。 It should work.它应该工作。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM