Coding Best Practice: Hiding Outer Variable Definitions

Warning: This post describes a somewhat advanced usage of a language “feature” that is usually considered to be extremely bad practice and (by some) outright dangerous. If you’re not familiar with the general danger of hiding outer variable declarations with inner ones, do yourself and all of your coworkers a favor and don’t read this! …

Continue reading ‘Coding Best Practice: Hiding Outer Variable Definitions’ »

Aside: Why don’t our languages support a dedicated poison value?

When writing my last blog post, I was struck by a really simple thought: why do our programming languages not include a provision for a distinct poison value or even set of poison values? For reference fields, we often end up using null for this purpose.  However, null often has another use in marking fields …

Continue reading ‘Aside: Why don’t our languages support a dedicated poison value?’ »