But checking every name could get tedious. How about we just look at every prefix-less class name that Apple has used?
If we were to use any of those classes, the compiler and linker would not complain. But if you used
AppleSpellin a video game to represent the spell an apple casts on your player, and you override some important methods like
initto do something relevant to your own game, you might start seeing very strange behavior!
Apple may roll out updates to frameworks between OS updates, which I believe has happened before. Ultimately the best solution is to test your app regularly and pay attention to your logs.
I wonder why Apple doesn’t have an internal tool to prevent shipping unprefixed classes.
Stay up-to-date by subscribing to the Comments RSS Feed for this post.