<p>One could argue the same is true of other languages as well. The whole Python `def f(x = []): x.append(&quot;foo&quot;)` problem is absolutely the language not being safe by default, and in a surprising way. Yes, the logic makes perfect sense once you&#39;re used to how Python works, but it is a hell of a footgun.</p><p>So there&#39;s absolutely an aspect of the above being a matter of degree. That&#39;s a pretty extreme degree, though, and I think is worth calling out.</p>
Reply