Python indentation
David Fraser
davidf at sjsoft.com
Fri Jul 9 15:44:05 EDT 2004
Peter Hansen wrote:
> Paramjit Oberoi wrote:
>
>>>> Yes, and I would also be interested in an other proposal
>>>> that went something like:
>>>>
>>>>
>>>> while condition1:
>>>> code1
>>>> and while condition2:
>>>> code2
>>>> and while condition3:
>>>> code3
>>
>>
>> Andrew Koenig proposed this in the following email:
>>
>> http://groups.google.com/groups?q=g:thl470833922d&dq=&hl=en&lr=&ie=UTF-8&selm=yu99isspv9mm.fsf%40europa.research.att.com
>>
>>
>> If link doesn't work - it was a post dated 2003-05-05 with the subject
>> "Re: PEP 315: Enhanced While Loop". There was a fairly long thread about
>> it back then.
>
>
> Andrew's interpretation doesn't fit mine. I look at
> the above and wonder why the code2 block doesn't
> continue to execute until condition2 fails, and then
> the code3 block loops repeatedly until condition3
> fails...
>
Which is exactly why the syntax proposal is bad - there are too many
interpretations of what it might mean...
David
More information about the Python-list
mailing list