I have an overloaded function, one version with a BOOL
parameter and one with a bool
parameter. It gives me a redefinition error when compiling for Apple Silicon but not when compiling for Intel.
This is mentioned in the Apple silicon porting guide:
On Apple silicon, the compiler defines the BOOL type to be a native bool, but on Intel-based Mac computers, it is a signed char.
But even though it works on Intel, I’d suggest that overloading that way could result in a confusing and error-prone API.