Search code examples
iosobjective-c32bit-64bitiphone-developer-program

Explicit function prototype | ios 64 bit architecture


In apple developer site (https://developer.apple.com) it's stated that while converting our iphone app from 32 bit to 64 bit architecture, we must write explicit prototype for functions so that compiler can determine whether the function is a variadic function or not. The link is as : apple developers/explicit prototype requirement

I'm unable to understand this thing that how to do this and if we have to write prototype for every function as, as per my information, there's no need of this. Kindly explain this thing

Regards


Solution

  • I think that the explicit function prototypes refer to C code, if your app is coded in Objective-C you are not going to have that problem.

    I think that the explicit function prototype requirement, is because the 64 bit runtime can pass parameters to functions using the stack or processors registers, and to achieve this, it needs to process the functions differently.