• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Xcode Debugger Shows Incorrect Variable Information
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Xcode Debugger Shows Incorrect Variable Information


  • Subject: Xcode Debugger Shows Incorrect Variable Information
  • From: Richard Charles <email@hidden>
  • Date: Fri, 07 Aug 2015 22:59:50 -0600

I have a heavily customized managed object with some attributes using ivar backing. I recently added an ivar of type NSObject and experienced some difficulty with the debugger. The simplified code is shown below.

@implementation MyManagedObject
{
     MyStruct _ivar1;
     MyStruct _ivar2; // debugger shows this is global variable
     MyStruct _ivar3;
     double _ivar4;

     NSObject *_ivar5; // recently added
}

- (void)awakeFromFetch
{
     [super awakeFromFetch];
     _ivar5 = [[NSObject alloc] init];

} // break point

@end

When a break point is placed at the closing brace of awakeFromFetch, the debugger shows that _ivar2 and only _ivar2 is a global variable (this is not correct).

If _ivar5 is removed from the code, then when a break point is placed at the closing brace of awakeFromFetch, the debugger shows no global variables whatsoever (this is correct).

http://stackoverflow.com/questions/9917646/what-do-the-icons-in-xcode-4s-debug-area-variable-list-mean

Any ideas?

--Richard Charles


_______________________________________________

Cocoa-dev mailing list (email@hidden)

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:

This email sent to email@hidden


  • Follow-Ups:
    • Re: Xcode Debugger Shows Incorrect Variable Information
      • From: Graham Cox <email@hidden>
  • Prev by Date: Re: Auto-layout annoyance
  • Next by Date: Re: Improve performance of data structure saved to disk
  • Previous by thread: Re: Auto-layout annoyance
  • Next by thread: Re: Xcode Debugger Shows Incorrect Variable Information
  • Index(es):
    • Date
    • Thread