Martin v. Löwis wrote:
> Steven Bethard schrieb:
>> Does this approach seem sound? Am I going to run into some weird
>> problems doing it this way?
>
> It's good, but I think rebuilding the object through
> new.instancemethod should be even better.
>
> py> class A:
> ... def f(self):print "A"
Steven Bethard schrieb:
> Does this approach seem sound? Am I going to run into some weird
> problems doing it this way?
It's good, but I think rebuilding the object through
new.instancemethod should be even better.
py> class A:
... def f(self):print "A"
...
py> class B(A):
... def f(self):p
I'd like to be able to pickle instancemethod objects mainly because I
want to be able to delay a call like ``foo(spam, badger)`` by dumping
``foo``, ``spam`` and ``badger`` to disk and loading them again later.
Sometimes the callable ``foo`` is actually a bound method, e.g.
``bar.baz``, but in