-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 On 06/15/2013 09:15 AM, Donald Stufft wrote: > I never want to iterate, but I love slice syntax and indexing. Don't > think you can have that w/o being able to loop over it can you? Maybe > I'm just thinking slow since I just woke up.
You could if '__iter__' raised an error ('NotIterable', maybe) which defeated the '__getitem__'/'__len__'-based fallback. Tres. - -- =================================================================== Tres Seaver +1 540-429-0999 tsea...@palladion.com Palladion Software "Excellence by Design" http://palladion.com -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.11 (GNU/Linux) Comment: Using GnuPG with undefined - http://www.enigmail.net/ iEYEARECAAYFAlG8cFoACgkQ+gerLs4ltQ7KcgCfdFCEkp2gBeuUgn/KooY7F5HX Jm8An2bwq8QoplwJ1MqIbS76m+xdl/Mk =6hA9 -----END PGP SIGNATURE----- _______________________________________________ Python-Dev mailing list Python-Dev@python.org http://mail.python.org/mailman/listinfo/python-dev Unsubscribe: http://mail.python.org/mailman/options/python-dev/archive%40mail-archive.com