[Python-ideas] For/in/as syntax

Alexandre Brault abrault at mapgears.com
Fri Mar 3 14:02:29 EST 2017


On 2017-03-03 01:52 PM, Chris Angelico wrote:
> On Sat, Mar 4, 2017 at 5:50 AM, Matthias Bussonnier
> <bussonniermatthias at gmail.com> wrote:
>> Thanks, I think it does make sens, I'm going to guess,
>> outerloop.brk(inners=True) might also be helpful if you have more
>> inners loops. I think that implicitely breaking inner ones might
>> not always be the right thing to do so having a way to not break
>> inner ones does make sens.
>>
> *scratches head* How do you break an outer loop without breaking the
> inner loop? What happens?
>
> ChrisA
> _______________________________________________
> Python-ideas mailing list
> Python-ideas at python.org
> https://mail.python.org/mailman/listinfo/python-ideas
> Code of Conduct: http://python.org/psf/codeofconduct/
I believe what Matthias is hoping for is an equivalent of Java's named
break feature. Breaking out of an outer loop implicitly breaks out of
all inner loops
Alex


More information about the Python-ideas mailing list