[Python-ideas] Cofunctions - Back to Basics
Paul Moore
p.f.moore at gmail.com
Sat Oct 29 18:22:35 CEST 2011
On 29 October 2011 15:48, Nick Coghlan <ncoghlan at gmail.com> wrote:
> On Sat, Oct 29, 2011 at 8:51 PM, Paul Moore <p.f.moore at gmail.com> wrote:
>> I think that if the runtime support can be built in a way that allows
>> a Lua-style function/method approach, then that should be the initial
>> design, as it's easier to tweak a functional API than to change
>> syntax. If experience shows that code would benefit from syntax
>> support, add that later.
>
> I have one specific reason I think the new yield variant should get a
> new keyword: it's a new kind of flow control, and Python has a history
> of trying to keep flow control explicit (cf. the PEP 343 with
> statement discussions).
That's a reasonable point, and could be explicitly noted in the PEP.
Paul.
More information about the Python-ideas
mailing list