I\'ve got an iPhone app that\'s mainly targetting 3.0, but which takes advantage of newer APIs when they\'re available. Code goes something like this:
if (UI
Aaand I figured it out. For symbols that are not functions (extern const int foobar
, for instance), you have to compare against the address of the symbol, not the symbol itself, so:
if (&UIApplicationWillEnterForegroundNotification != NULL)
etc;
Which in retrospect is kind of obvious, but I still fault the entire universe around me for not ever mentioning the distinction.