[Python-3000] Builtin iterator type
Greg Ewing
greg.ewing at canterbury.ac.nz
Mon Nov 20 01:01:10 CET 2006
Andrew Koenig wrote:
> That's a nice general sentiment, but not always feasible -- especially if
> you're writing library code.
I've written a fair bit of library code, and I've never
found a pressing need to test for an abstract interface.
In the rare cases where I've used type testing in an
API, it's always been for specific well-known concrete
types, such as strings and tuples -- never anything so
abstract as "iterator", "sequence", etc.
--
Greg
More information about the Python-3000
mailing list