with statement support

7 views
Skip to first unread message

Alejandro Martinez

unread,
Apr 26, 2013, 5:23:00 PM4/26/13
to lamb...@googlegroups.com
One of the major statement-level shortcomings of lambda-py is the lack of support for the with statement (the other being the lack of support for metaclass programming), I plan to give it a try in the following days, the steps would be as follows:

    1) add PyWith(context, target, body) to surface language and get-structured-python
    2) add LexWith(context, target, body) to lexical language taking care of target variables
    3) desugar LexWith according to http://www.python.org/dev/peps/pep-0343/
    4) add support for the context manager protocol to file objects

Any comments or suggestions are welcomed.

Alejandro.

Alejandro Martinez

unread,
May 2, 2013, 4:30:45 PM5/2/13
to lamb...@googlegroups.com
This is finished, I will take a look at metaclasses now.
Reply all
Reply to author
Forward
0 new messages