3 ms·
> It does not cause undefined behavior. I haven't read the standard. I am just stating what TFA says. So are you saying it is inaccurate?
by perryizgr8 5y ago
> It does not cause undefined behavior.
I haven't read the standard. I am just stating what TFA says. So are you saying it is inaccurate?
- _kst_ 5y agoYes, it's inaccurate. Here's what the C90 standard says: 5.1.2.2.3 Program termination A return from the initial call to the main function is equivalent to calling the exit function with the value returned by the main function as its argument. If the main function executes a return that specifies no value, the termination status returned to the host environment is undefined.