UrbanAirship SDK: "Not a prototype" warning on UAPushNotificationDelegate

We turned on some warnings recommended by Apple (in WWDC sessions this year), including "Strict Prototypes" (`-Wstrict-prototypes`). When integrating UrbanAirship we get warnings based on UAPushNotificationDelegate's completion callbacks that are tagged as `void (^)()` -- Apple's Compiler Engineers explicitly warn this as dangerous, because it forces the compiler to allow calling with arbitrary parameters which could lead to explosions because the calling convention might shift.

Screenshot of the warning in our implementation file:
https://cl.ly/3k0J301d3931

We integrated UrbanAirship through CocoaPods.

- Frederic Barthelemy

Didn't find what you were looking for?

New post

Comments

3 comments

  • Specifically: the expectation is that a block that accepts no parameters should be typed as:
    `void (^)(void)`

    Comment actions Permalink
    0
  • Disabled the warning just for our UAPushNotificationDelegate with the following code: https://cl.ly/0W0S450t2M2k

    Comment actions Permalink
    0
  • Hi Frederic,

     

    iOS 11 and Xcode 9 are currently in beta and are therefore not supported by the current release of the SDK(8.3.3).

    Having said that, any bug information will be useful to our Mobile team whilst they work on supporting these new versions. I'll therefore pass this on to them for review.

     

    Comment actions Permalink
    0

Please sign in to leave a comment.