looking for tips on how to implement "ruby-style" Domain Specific Language in Python

Jonathan Gardner jgardner at jonathangardner.net
Tue Jan 6 14:04:27 EST 2009


On Jan 6, 8:18 am, sturlamolden <sturlamol... at yahoo.no> wrote:
> On Jan 6, 4:32 pm, mark <mark.fi... at googlemail.com> wrote:
>
> > I want to implement a internal DSL in Python. I would like the syntax
> > as human readable as possible.
>
> Also beware that Python is not Lisp. You cannot define new syntax (yes
> I've seen the goto joke).

This isn't really true. You can, for instance, write a program (in
Python) that takes your pseudo-Python and converts it into Python.
This is what a number of templating libraries such as Mako do.



More information about the Python-list mailing list