[Python-Dev] 'With' context documentation draft (was Re: Terminology for PEP 343 (original) (raw)

Nicolas Fleury nidoizo at yahoo.com
Thu Jul 7 03:17:11 CEST 2005


Fred L. Drake, Jr. wrote:

On Wednesday 06 July 2005 19:47, Raymond Hettinger wrote: > These names should be changed to beginwith and endwith. The > current names are too vague, not obviously paired with each other, not > obviously tied to the with-statement, and provide no hint about what > calls them. Remember, the methods will appear among a slew of other > methods that have nothing to do with with-statements. There will be no > surrounding contextual clue as to what these methods are for.

I don't really like this; what's to say there won't be some other client of the context protocol? Should iter have been iterfor? (I don't think so.)

Then what about begincontext and endcontext? Raymond's points about enter and exit are still good.

Regards, Nicolas



More information about the Python-Dev mailing list