Check for private API usage conflicts with Core Data
| Originator: | craig.hockenberry | ||
| Number: | rdar://12730626 | Date Originated: | |
| Status: | Open | Resolved: | |
| Product: | App Store | Product Version: | N/A |
| Classification: | Serious Bug | Reproducible: | Always |
Summary:
An application that uses a Core Data model with an attribute named "type" can't be submitted to the iOS App Store.
Steps to Reproduce:
1) Create a Core Data model with an attribute named "type" and set it to be a "Integer 16".
2) Add interface declarations for the "type" property's class:
- (NSNumber*)primitiveType;
- (void)setPrimitiveType:(NSNumber*)value;
3) Add interface declarations to access the "type" property's value:
- (int16_t)primitiveTypeValue;
- (void)setPrimitiveTypeValue:(int16_t)value_;
4) Implement the accessors for the "type" property's value:
- (int16_t)primitiveTypeValue {
NSNumber *result = [self primitiveType];
return [result shortValue];
}
- (void)setPrimitiveTypeValue:(int16_t)value_ {
[self setPrimitiveType:[NSNumber numberWithShort:value_]];
}
5) Compile a binary and submit it to the iOS App Store using the Application Loader.
Expected Results:
The submission should be accepted.
Actual Results:
The submission generates a warning about private API usage:
"The app references non-public selectors in Twitterrific.app/Twitterrific: primitiveType, setPrimitiveType:
Regression:
N/A
Notes:
The selectors are not used elsewhere in the app.
The primitive selectors were generated with the mogenerator tool:
https://github.com/rentzsch/mogenerator
Comments
Please note: Reports posted here will not necessarily be seen by Apple. All problems should be submitted at bugreport.apple.com before they are posted here. Please only post information for Radars that you have filed yourself, and please do not include Apple confidential information in your posts. Thank you!