[Python-ideas] Statements vs Expressions... why?

Cliff Wells cliff at develix.com
Mon Sep 15 04:10:11 CEST 2008


On Sun, 2008-09-14 at 22:58 -0300, Leonardo Santagada wrote:

> I was having fun reading the discussion, specially now that it got to  
> the part were most people are starting to realise how ugly python  
> would become, to put it lightly we got to the dificult part (the "how").
> 
> But all Cliff wanted is to have better support for DSL in python, that  
> is his real use case. I say why don't we focus on it.
> 
> The only clean way to support DSL in python in my view would be to  
> support something like pyparsing or ANTLR and make it generate a  
> parser and some simple form of compilation to python bytecodes. How  
> can we support that? Is this even desired?

Actually you can do quite a lot with plain objects and class magic.  But
if your DSL isn't purely procedural (Breve is declarative-functional)
then you are left without much in the way of flow control as most flow
control in Python is done via statements.

Overall I've already made a decision about my programming future, but
certainly better DSL support in Python would be a good thing.

Regards,
Cliff





More information about the Python-ideas mailing list