• 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
ARC not ready for primetime?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

ARC not ready for primetime?


  • Subject: ARC not ready for primetime?
  • From: Scott Andrew <email@hidden>
  • Date: Sat, 24 Mar 2012 01:17:40 -0700

I seem to have hit a few limitations with ARC.

1.) Subclasses of CALayer are not being fully released which causes my view controller to remain around. There is still some small bit of memory being left behind. Even if I do the following simple code:

-(void) viewDidLoad {

    [super viewDidLoad];

    CNFooLayer* foo = [CNFooLayer layer];

    [self.view.layer addSublayer:cup];
}

Cup is:

@interface CNFooLayer : CALayer
@end


If you change the above too:

	[super viewDidLoad];

    CALayer* foo = [CALayer layer];

    [self.view.layer addSublayer:cup];

all is good.

If I watch the object list the object allocations you can see that there is residual memory left behind and my view controller is still around (even though dealloc was called).

2.) I have a simple class with lost of properties that if i alloc and init it will cause my hand created view controller to stick around. Remove the alloc in the view controller and all is fine.

I seem to be at the point now where need to remove arc and go back to retain, release. The weird thing is leaks has no leaks, watching for my viewController in statistics shows that it has gone away. However heapshot shows residual and so does the object list.

_______________________________________________

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: ARC not ready for primetime?
      • From: Dave Zarzycki <email@hidden>
    • Re: ARC not ready for primetime?
      • From: "T.J. Usiyan" <email@hidden>
  • Prev by Date: Technology recommendations for animation/display
  • Next by Date: Re: Binding and multithreading
  • Previous by thread: Re: Technology recommendations for animation/display
  • Next by thread: Re: ARC not ready for primetime?
  • Index(es):
    • Date
    • Thread