X3J16/95-0090 WG21/N0690 Proposal to reinstate the meaning of main() {} Bruce Eckel Until very recently, the draft has defined the meaning of the special case main() {} to be interpreted by the compiler as: int main() { return 0; } (whether or not there are arguments). However, the addition of the "no default to int" rule, while generally very good, has implicitly removed the meaning of the above special case. I propose to reinstate what we've been saying all along. Rationale: 1) main() is a special case. Aside from the fact that every program must have one and only one main-like function, it's not ordinary in the sense that its return value goes to the operating system. Some of the most widely-used operating systems don't do anything with this value. It is also not ordinary in the sense that it does not participate in overloading in the ordinary way: main() and main(int, char**) are the same function. 2) When teaching C++, you can't get a program to work without explaining main() first. It's helpful to be able to skip over the details while trying to give the big picture. 3) It may introduce a gratuitous C incompatibility. In C, the effect of main() { } is well-defined except for the value it returns to the operating system, which is unspecified.