“No previous prototype for function” warning

前端 未结 4 1635
情歌与酒
情歌与酒 2021-02-01 12:59

i use shareKit to myself program .

but in the FBConnectGlobal, there are some warning,

NSMutableArray* FBCreateNonRetainingArray() {
  CFArrayCallBacks c         


        
4条回答
  •  天涯浪人
    2021-02-01 13:43

    To clarify Eric Dchao's answer above, someone at facebook apparently didn't put a "static" in front of that BOOL?

    Anyways, changing from this

    BOOL FBIsDeviceIPad() {
    #if __IPHONE_OS_VERSION_MAX_ALLOWED >= 30200
      if (UI_USER_INTERFACE_IDIOM() == UIUserInterfaceIdiomPad) {
        return YES;
      }
    #endif
      return NO;
    }
    

    to this

    static BOOL FBIsDeviceIPad() {
    #if __IPHONE_OS_VERSION_MAX_ALLOWED >= 30200
      if (UI_USER_INTERFACE_IDIOM() == UIUserInterfaceIdiomPad) {
        return YES;
      }
    #endif
      return NO;
    }
    

    fixed it for me.

提交回复
热议问题