I'm debugging an iOS app with Xcode 4.5.1 in Mountain Lion 10.8.2 using lldb.
Sometimes I'll try to examine an iVar in the debugger window when at a breakpoint using:
po _currentSale
and will receive the reply:
Printing description of self->_currentSale: (Sale *) _currentSale = 0x081cd7e0
and other times I'll receive this reply (which is what I want):
Printing description of self->_currentSale: '<'Sale: 0x81cd7e0'>' (entity: Sale; id: 0x81dd670 ; data: { cardNumber = "\U2022\U2022\U2022\U2022\U2022\U2022\U2022\U2022\U2022\U2022\U2022\U20220001"; cvv = 222; emailAddress = "k@w.com"; expirationDate = 0413; lastStatus = approved; purchaseNumber = 00000008; saleAmount = 230; saleDate = "2012-10-20 08:06:45 +0000"; sectionIdentifier = 20121020; tipPercentage = 15; transactions = ( "0x75df620 '<'x-coredata://4A0DEB78-C770-4CE2-8A5D-878F51294D6D/Transaction/p11'>'" ); zipCode = 33333; })
Why does the reply vary between giving me the object address sometimes and the complete description others? My Sale object is a Core Data object (if it makes any difference).