I'd like to change the syntax of my module 'codeblocks' to make it more
pythonic.
Current Syntax:
with res << func(arg1) << 'x, y':
print(x, y)
with res << func(arg1) << block_name << 'x, y':
print(x, y)
New Syntax:
with res == func(arg1) .taking_block (x, y):
print(x, y)
with res == func(arg1) .taking_block (x, y) as block_name:
print(x, y)
The full form is equivalent to
def anon_func(x, y):
print(x, y)
res = func(arg1, block_name = anon_func)
Suggestions?
Kiuhnm
--
http://mail.python.org/mailman/listinfo/python-list