Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

It sure leads to brittle code if assumptions and contracts in the code are not crystal clear, but Carmack's point in this particular article was about writing "consistently performing" code which doesn't degrade under specific conditions.

In my refactored example, you wouldn't be eventually calling `is_player_untouched()` once more if `some_other_condition` is true.



Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: