Terry Reedy schrieb: >>Unfortunately, for implementation reasons you can't modify most >>built-in (and some user-defined) classes in this fashion: >> >> > >Being able to add Python-coded functions as methods of compiled C-coded >types/classes (builting or otherwise) would require some wrapping machinery >that would slow down normal usage. > > Getting rid of C-coded types is certainly an interesting requirement as well. I hope PyPythonistas may agree :)
Honestly, I don't understand how a pointer on an implicit/interpreter level Trait that stores user defined methods for builtins would slow execution down. You would need wrappers only if you permit replacing/deleting pre-defined methods and I don't see reasons to be permissive here. Kay _______________________________________________ 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
