4 ms·
I found this a bit confusing as well at first, but it's really simple enough: The point of the article isn't the scripting language itself. It's that the author
by nhaehnle 11y ago
I found this a bit confusing as well at first, but it's really simple enough: The point of the article isn't the scripting language itself. It's that the author encountered a bug in the scripting language implementation that would have been found much earlier if the compiler had warned about the argument that is de facto unused.
This is a general point: More warnings can help find more bugs earlier - but you do have to worry about false positives, and warnings that increase compile time can also be a net negative.
The author's example is probably simple and efficient enough to add to a compiler, assuming that it performs some basic recursion analysis already.