C ++ has an explicit rule that prohibits references or pointers to arrays without borders as parameters (but these are otherwise valid types). The following will be a valid argument for such a parameter.
extern int arg[];
Please note: you cannot use an array with size. In C ++, there is no concept of type compatibility. C has and creates an array type without size compatible with the corresponding array type with size. In C ++, the type system is more stringent, types have relationships and prototype function types do not exist, so type compatibility is not a real need, so C ++ abandoned it.
source share