Hacker News new | ask | show | jobs
by zh3 1040 days ago
Some great in-jokes there (hands up who gets the EBCDIC one).

More seriously, a lot of the discussions about "undefined behaviour" seem to be aimed at the kind of code that no experienced engineer would write anyway. Until there's a language that's proved formally correct, every language is going to have "undefined" behaviour (though some languages - especially more modern ones - cover more cases/make it harder for less experienced users to blow their foot [or worse, someone elses] off).

1 comments

Half of it is code no engineer would write and the other half of it occupies 30% of any sufficiently old C codebase. And usually the only way you find out that your clever new optimization is going to break the latter is to write a lot of the former.