Fail Fast

Good code handles a thousand nit-picky edge cases. But sometimes, you don’t need to handle all those edge cases yet. You can save time by making your code fail fast. Make the code fail clearly and obviously, with good error messages, and you can skip unneeded edge cases now without worrying about forgetting them in the future.

comments powered by Disqus