break in a module
Ian Kelly
ian.g.kelly at gmail.com
Fri Jun 17 00:50:21 EDT 2011
More information about the Python-list mailing list
Fri Jun 17 00:50:21 EDT 2011
- Previous message (by thread): break in a module
- Next message (by thread): break in a module
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
On Thu, Jun 16, 2011 at 10:24 PM, Erik Max Francis <max at alcyone.com> wrote: > True. So let's use `in` to represent breaking out of the top-level code of > a module. Why not, it's not the first time a keyword has been reused, > right? > > The point is, if it's not obvious already from that facetious proposal, it's > not a good idea to reuse keywords that really read very differently than > their original use. Reusing `break` (or `return`) this way would be rather > abusive. Yes, using `in` to mean "break out of a block" would obviously be a terrible choice, since the word "in" has nothing to do with breaking. I really don't see why using `break` to mean "break out of a block" is counter-intuitive, especially since as you point out it is already used that way for two particular types of blocks. The proposed usage merely adds a third type. I think a stronger objection might be that it disrupts the homology of `break` and `continue`, since continuing a module is meaningless.
- Previous message (by thread): break in a module
- Next message (by thread): break in a module
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
More information about the Python-list mailing list