On 7/18/07, Greg Ewing <[EMAIL PROTECTED]> wrote: > Guido van Rossum wrote: > > Sorry, but I'm still totally uncomfortable with this. While I admit > > the feature exists, I really, really, really don't want it to be used > > on a regular basis. > > As long as the objects defined by a regular def statement > aren't modifiable, it seems like it won't be possible > to support retroactive generification of functions that > haven't initially been defined as generic somehow. > > So effectively you're saying that you're against this, > or willing to forego it? Not arguing one way or the > other, just seeking to clarify your position.
The only approach to retroactive generification that I approve of is replacing the entire object with a wrapper of sorts, e.g. foo = generify(foo) or (more likely) import bar bar.foo = generify(bar.foo) I know this has a downside when someone else did "from bar import foo" before the generification was applied; that is a general problem with "from foo import bar" and should be addressed by not using that style in cases where this matters. (It is fine for importing a submodule from a package of course.) -- --Guido van Rossum (home page: http://www.python.org/~guido/) _______________________________________________ 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