[Python-ideas] Anonymous blocks (again):

Nick Coghlan ncoghlan at gmail.com
Sun May 12 07:17:32 CEST 2013


On Sun, May 12, 2013 at 3:15 PM, Nick Coghlan <ncoghlan at gmail.com> wrote:
> Or, if PEP 403 were accepted and implemented:
>
>     @in closure(f):
>     def f():
>         self.rule()
>         self.ast['rules'] = self.last_node

Oops, typo in that example (the extra colon on the @in expression):

    @in closure(f)
    def f():
        self.rule()
        self.ast['rules'] = self.last_node

Cheers,
Nick.

--
Nick Coghlan   |   ncoghlan at gmail.com   |   Brisbane, Australia



More information about the Python-ideas mailing list