5 ms·
The problem with eval is the principle of least power. He almost figured it out when he said it was too much tool for the job, but then he went on to useless me
by calcnerd256 17y ago
The problem with eval is the principle of least power. He almost figured it out when he said it was too much tool for the job, but then he went on to useless metrics.
- lucumo 17y agoAs far as I can tell, the principle of least power[1] applies to descriptive languages (HTML, RDF, etc.) that are meant to store information. A program by comparison is meant to store instructions. I'm unsure about the argument you're making. Can you elaborate a bit? [1] For those that had to look it up like I had to: http://en.wikipedia.org/wiki/Principle_of_Least_Power http://en.wikipedia.org/wiki/Principle_of_Least_Power
- calcnerd256 17y agoI recommend treating it as a spectrum instead of boolean. Eval is considered harmful for a similar reason as to why GOTO is: it makes code harder to prove and to manipulate. Markup and data on one end of the spectrum can be endlessly manipulated, analyzed, and worked with. As we move up the power spectrum, we get to regular languages, stack languages, and finally Turing-completeness. Within Turing-completeness, though, there are still varying levels of how hard something is to work with. Yes, the halting problem means that you can't for any behavior determine whether an arbitrary program exhibits that behavior, but there are still subsets about which you can reason.