3 ms·
Yes. To spell it out: undefined behaviour doesn't just affect specific values nor just the behaviour of your program after triggering UB. It's the entire beha
by eru 4y ago
Yes. To spell it out: undefined behaviour doesn't just affect specific values nor just the behaviour of your program after triggering UB. It's the entire behaviour of your programme. So UB can 'travel backwards in time'.
Fun fact: not closing a string literal is UB. Ending a non-empty source file in anything other than a newline is also UB.