Yes Yes. Does not have a UB declaration.
J.2 Undefined Behavior
- to call a function without a function prototype, in which the function is defined using the prototype function, or the prototype ends with an ellipsis or types of arguments after promotion, parameters that are not compatible with types (6.5.2.2).
Also, note that the failure is from the main side in C99 (i.e., it is semantically equivalent to a return 0; ). For pre-C99 compatible compilers, you need a return statement, where the return type of the main function is an int compatible type.
source share