If the return type is not specified, it is implicitly declared as int.
According to C99 rationale (
http://port70.net/~nsz/c/c99/)
A new feature of C99: In C89, all type specifiers could be omitted from the declaration specifiers in a declaration. In such a case int was implied. The Committee decided that the inherent danger of this feature outweighed its convenience, and so it was removed. The effect is to guarantee the production of a diagnostic that will catch an additional category of programming errors. After issuing the diagnostic, an implementation may choose to assume an implicit int and continue to translate the program in order to support existing source code that exploits this feature.
From C99 or later, warnings are likely to be generated: "-Wimplicit-int" (
https://gcc.gnu.org/onlinedocs/gcc/W...arning-Options).
On testing the above code with TDM-GCC 4.9.2 64-bit Release, no warning was there.
With GNU GCC,
"warning: return type defaults to 'int' [-Wimplicit-int]" -> likely targeting the C99 or later version.