From a C language point of view, this code is perfectly legal.
#include<stdio.h>
void main(){
printf("Hello world");
}
So the only possibility is that the compiler do not conform to C language or do not run in C mode. As
PIEBALDconsult
said, "It is compiler dependent".