On 8/23/06, Barry Warsaw <[EMAIL PROTECTED]> wrote: > I agree with Tim -- if we have to get rid of one of them, let's get > rid of index/rindex and keep find/rfind. Catching the exception is > much less convenient than testing for -1.
But the -1 is very error-prone, as many have experienced. Also, many uses of find() should be replaced by 'in' (long ago, 'in' only accepted one-character strings on the left and find() was the best alternative) or partition(). To the folks asking for it to stay because it's harmless: in py3k I want to rip out lots of "harmless" to make the language smaller. A smaller language is also a feature, and a very important one -- a frequent complaint I hear is that over time the language has lost some of its original smallness, which reduces some of the reasons why people were attracted to it in the first place. (Also, removing features makes room for new ones -- Bertrand Meyer, Eiffel's creator, often asks users demanding a new feature to point out which feature they are willing to drop to make room.) I don't want Python to become like Emacs, which I still use, but generally don't recommend to new developers any more... If you haven't grown up with it, its current state is hard to understand and hard to defend. -- --Guido van Rossum (home page: http://www.python.org/~guido/) _______________________________________________ Python-3000 mailing list [email protected] http://mail.python.org/mailman/listinfo/python-3000 Unsubscribe: http://mail.python.org/mailman/options/python-3000/archive%40mail-archive.com
