• 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
Re: ARC conversion issue problem with Xcode 4.2
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: ARC conversion issue problem with Xcode 4.2


  • Subject: Re: ARC conversion issue problem with Xcode 4.2
  • From: Quincey Morris <email@hidden>
  • Date: Sat, 15 Oct 2011 23:02:42 -0700

On Oct 15, 2011, at 18:02 , Sean Todd wrote:

> I am trying to convert a Core Data app which uses garbage collection to ARC. When I run the refactoring tool, I see issues like:
>
> Semantic Issue: Type of property 'person' does not match type of accessor 'setPerson:'

It's really, really important when asking a question like this to tell us which line the error message is issued for.

> The relevant  declaration code:
>
> @class ABPerson;
>
> @interface XG2Student :  NSManagedObject {
> }
>
> @property (nonatomic, retain) ABPerson * person;
>
> - (ABPerson *)person;
> - (void)setPerson:(ABPerson *)aPerson;

I'm guessing that the problem is this totally unnecessary redeclaration of the property accessors. Just omit the above 2 lines -- they serve no purpose whatsoever.

> The relevant implementation:
>
> @implementation XG2Student
>
> @dynamic person;
>
> /* custom getter omitted for brevity */
>
> - (void)setPerson:(ABPerson *)aPerson {
>
> [self willChangeValueForKey:XG2PersonKey];
> [self setPrimitivePerson:aPerson];
> [self didChangeValueForKey:XG2PersonKey];
>
> self.personUID = [aPerson uniqueId];	// this is the value that is persisted
> }


_______________________________________________

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 conversion issue problem with Xcode 4.2
      • From: Sean Todd <email@hidden>
References: 
 >ARC conversion issue problem with Xcode 4.2 (From: Sean Todd <email@hidden>)

  • Prev by Date: CFDictionarySetValue and ARC
  • Next by Date: Re: CFDictionarySetValue and ARC
  • Previous by thread: ARC conversion issue problem with Xcode 4.2
  • Next by thread: Re: ARC conversion issue problem with Xcode 4.2
  • Index(es):
    • Date
    • Thread