4 ms·
Both of those programs are playing with C's infamously broad undefined behavior rules, the first for a non-terminating loop and the second for using too much st
by bcoates 14y ago
Both of those programs are playing with C's infamously broad undefined behavior rules, the first for a non-terminating loop and the second for using too much stack (when called with a sufficiently large number). -O2 being nice to you is a coincidence, not something you should rely on.
In a language which prefers diagnosing programmer error over punting both should be errors.