Posted Apr 23, 2012 10:42 UTC (Mon) by mpr22
In reply to: Not Again
Parent article: PHP: a fractal of bad design (fuzzy notepad)
The result of void main(void) is only formally undefined if you're targeting a hosted implementation (which, admittedly, application programmers generally are). If you're using a freestanding implementation, then both the type and the name of your program's entry point are implementation-defined, so main might not be magic and even if it is, it might legitimately have a return type of void.
(Note to self: check whether it's defining void main(/*whatever*/) or returning from main having done so, that crosses the undefined-behaviour threshold on hosted implementations.)
to post comments)