-----BEGIN PGP SIGNED MESSAGE----- Hash: SHA1 On Mar 12, 2007, at 11:06 PM, Phillip J. Eby wrote:
> In short, the very idea of 'is_file()' is wrong, wrong, wrong. At > least, > if your goal is to make libraries more robust and reusable. It leads > inevitably to the brokenness seen in Pydoc -- and the comparable > brokenness > that existed in Zope prior to its replacing most introspection by > adaptation. (To be honest, I'm *assuming* that those broken bits > went away > as soon as adaptation became the recommended option -- I don't know > if it > really did or not, as I haven't done any real Zope work in a few > years.) Two other things I wanted to mention. One, I do think adaptation is an important (necessary?) aspect to any interface solution for exactly the reasons you state. Second, I think the other thing that bugs me about a pure-generics solution is that all the generic functions seem to want to live in a global namespace. That's fine for len() or iter() or keys(), but not so good for all_nonbouncing_regular_delivery_members(). In that sense, for more domain-specific functionality, it just seems that interfaces (w/ adaptation for that extra level of abstraction) is the object- oriented approach to generics. - -Barry -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.5 (Darwin) iQCVAwUBRfaqAnEjvBPtnXfVAQKH7gQAsLqXQ1/v+yU8XXXdWyN8Ear65JrXrurz RS/YwvjJEeASaq5p34jqTf6tzKL7txM7mxZmqTNUvGb5OW/hc1sENQHVn4tgeTD4 +U3KMR4xg31+84QWIzUB3VU88WNOkUqmwWATguiuNWrQZHSG7DEgxBxzLYOS9iTA VehDU4WUNHE= =Rfqn -----END PGP SIGNATURE----- _______________________________________________ Python-3000 mailing list Python-3000@python.org http://mail.python.org/mailman/listinfo/python-3000 Unsubscribe: http://mail.python.org/mailman/options/python-3000/archive%40mail-archive.com