I have a NSManagedObject subclass, created by the XCode model interface.
This class has some NSString and NSNumber members, and a NSDate member.
When I try to set the NSDate member, I get the following exception:
2009-10-12 21:53:32.228 xxx[2435:20b] Failed to call designated initializer on NSManagedObject class 'Item'
2009-10-12 21:53:32.228 xxx[2435:20b] *** -[Item setDate:]: unrecognized selector sent to instance 0x3f7ed30
2009-10-12 21:53:32.229 xxx[2435:20b] *** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '*** -[Item setDate:]: unrecognized selector sent to instance 0x3f7ed30'
The date parameter is just like the others, except that instead of being a
@property (nonatomic, retain) NS{String,Number}* propname;
it's a
@property (nonatomic, retain) NSDate *date;
Btw, the Item
instance I'm assigning on is just a regular [[Item alloc] init]
, no associated context or anything.
First I thought my NSDate* was faulty, then I tried assigning it [NSDate date], and even nil. It still crashes.
Any ideas?