LoginSignup
3
3

More than 5 years have passed since last update.

iOSデバッグ時のモジュールインポート

Posted at

iOSデバッグ時にたまに直面する問題

(lldb) p self.view.window.bounds
error: property 'bounds' not found on object of type 'id'
error: 1 errors parsing expression

これは型情報がなくて発生するようで以下のようにすれば表示できる

(lldb) p (CGRect)[self.view.window bounds]
(CGRect) $0 = (origin = (x = 0, y = 0), size = (width = 320, height = 568))

でもXcode6.3からはモジュールのインポートでも解決できる

(lldb) p @import UIKit
(lldb) p self.view.window.bounds
(CGRect) $1 = (origin = (x = 0, y = 0), size = (width = 320, height = 568))

参考:http://furbo.org/2015/05/11/an-import-ant-change-in-xcode/

3
3
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
3
3