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

M.-A. Lemburg mal at egenix.com
Tue Jan 6 21:11:40 CET 2009

On 2009-01-06 20:42, Kay Schluehr wrote:
>> How would one approach this in Python? Do I need to build a custom
>> loader which compiles *.dsl files to *.pyc files? Is it possible to
>> switch between the custom DSL and the standard Python interpreter?

> Sure, but there is no way to avoid extending the Python parser and
> then your DSL becomes external.

Try python4ply:


...much easier to work with than extending the Python parser by hand.

Marc-Andre Lemburg

Professional Python Services directly from the Source  (#1, Jan 06 2009)
>>> Python/Zope Consulting and Support ...        http://www.egenix.com/
>>> mxODBC.Zope.Database.Adapter ...             http://zope.egenix.com/
>>> mxODBC, mxDateTime, mxTextTools ...        http://python.egenix.com/

::: Try our new mxODBC.Connect Python Database Interface for free ! ::::

   eGenix.com Software, Skills and Services GmbH  Pastor-Loeh-Str.48
    D-40764 Langenfeld, Germany. CEO Dipl.-Math. Marc-Andre Lemburg
           Registered at Amtsgericht Duesseldorf: HRB 46611

More information about the Python-list mailing list