why no "do : until"?

Remco Gerlich scarblac at pino.selwerd.nl
Sun Dec 31 07:17:08 EST 2000


Steve Lamb <grey at despair.rpglink.com> wrote in comp.lang.python:
> On Sat, 30 Dec 2000 21:12:13 -0500, Peter Hansen <peter at engcorp.com> wrote:
> >I understand the point you are making; I'm just pointing out that the
> >opposing views seem well-founded.  Areas where I think you missed the
> >point are in the importance of code maintainability, the increased
> >complexity with your suggested approach, and the feelings of the "entire
> >CS community" on this issue.
> 
>     I seriously doubt that initing a variable before use causes either code
> maintainability problems or increased complexity.

It can hide bugs. If you use an unitialized variable, Python complains
loudly, pointing out some problem with your code, maybe a control flow
bug or a misspelled name or so. Initializing it beforehand makes those
bugs harder to find.

-- 
Remco Gerlich




More information about the Python-list mailing list