fudge.patcher does not work for staticmethods

Issue #5 new
Kumar McMillan
repo owner created an issue

Fudge needs to detect staticmethod functions when replacing them and act accordingly. This shows a staticmethod patching scenario:


class A: ... b = staticmethod(lambda: "foo") ... A.b() 'foo' A.b = lambda: "oyz" A.b() Traceback (most recent call last): File "<stdin>", line 1, in ? TypeError: unbound method <lambda>() must be called with A instance as first argument (got nothing instead) A.b = staticmethod(lambda: "oyz") A.b() 'oyz' }}}

Comments (0)

  1. Log in to comment