Why does the Interpreter Pattern suck?

2020-05-27 03:27发布

In Steve Yegge's review of Design Patterns, he calls the Interpreter Pattern an "in-joke". He goes on to talk about how the perception of compilers have changed, yet how interpreted languages are still s*** on, although I can't see how this ties into the pattern.

Anyone want to enlighten this ignorant student?

3条回答
仙女界的扛把子
2楼-- · 2020-05-27 03:49

That was irony :) Everybody loves interpreted languages nowadays but 10 years earlier people just thought they are too slow for anything practical. Much like today most of people thinks about static vs. dynamic typing.

查看更多
Viruses.
3楼-- · 2020-05-27 03:58
冷血范
4楼-- · 2020-05-27 04:02

The INTERPRETER pattern sucks because it's a codification of Greenspun's tenth rule:

Any sufficiently complicated C or Fortran program contains an ad hoc, informally-specified, bug-ridden, slow implementation of half of Common Lisp.

This was stated in 1993. A modern addendum might include C++ and Java.

查看更多
登录 后发表回答