> greg <[EMAIL PROTECTED]> writes: > > >> A compiler shifts a lot of decisions that an > >> interpreter would have to make at runtime to compile-time. There is > >> no reason a dynamic language can't enjoy this efficiency. > > > > I'm not saying that it's impossible to compile > > Python, only that's there's a lot more to it than > > just macro expansion. The OP was saying something > > like "If you added macros, you might get a compiler > > for free", which is clearly far from true.
Speaking as the OP, let's see what the OP really said: >... compilers are GREATLY facilitated by having a > macro facility because (at first blush) all you need to do is to > macro-expand down to something you know how to turn into code. > This isn't the only, nor perhaps the best way to get a compiler, but it's > a step in that direction. Later on you can learn the other great > features offered by homogeneous syntax, like being able to write code > walkers, which help improve over the "first blush" compiler.... So, "If you added macros, you might get a compiler for free" is not a fair paraphrase of this. (Another way, BTW, that macros improve efficiency is by replacing function calls with in-line code. Another cheap improvement facilitated by macros.) -- http://mail.python.org/mailman/listinfo/python-list