Index: TODO =================================================================== diff -u -r441c083eb3b4f9084f03aace7d990a1d40521c88 -r51a8a78d1718e0335a692661f7d1d84f19ba0601 --- TODO (.../TODO) (revision 441c083eb3b4f9084f03aace7d990a1d40521c88) +++ TODO (.../TODO) (revision 51a8a78d1718e0335a692661f7d1d84f19ba0601) @@ -1396,6 +1396,8 @@ - handle next in ensemble with arguments - extended regression test +- removed obsolete code + TODO: - subcmd * handle sucmd for other method factories Index: generic/nsf.c =================================================================== diff -u -r441c083eb3b4f9084f03aace7d990a1d40521c88 -r51a8a78d1718e0335a692661f7d1d84f19ba0601 --- generic/nsf.c (.../nsf.c) (revision 441c083eb3b4f9084f03aace7d990a1d40521c88) +++ generic/nsf.c (.../nsf.c) (revision 51a8a78d1718e0335a692661f7d1d84f19ba0601) @@ -6377,12 +6377,8 @@ } /* - * The client data cp is still the obj of the called method, - * i.e. self changes. In order to prevent this, we save the - * actual object in the runtime state, flag ObjectDispatch via - * NSF_CM_DELGATE to use it. + * The client data cp is still the obj of the called method */ - rst->delegatee = object; if (objc < 2) { result = DispatchDefaultMethod(cp, interp, objc, objv); } else { @@ -6662,24 +6658,8 @@ } if (!unknown) { - if (flags & NSF_CM_DELGATE && rst->delegatee) { - /* - * We want to execute the method on the delegatee, so we have - * to flip the object. - * - * Note: there is a object->refCount ++; at the begin of this - * function and a NsfCleanupObject(object) at the end. So, - * we have to keep track of the refcounts here. Either mangle - * refcounts, or save originator. - * - */ - result = MethodDispatch(rst->delegatee, interp, objc-shift, objv+shift, - cmd, rst->delegatee, cl, - methodName, frameType); - } else { - result = MethodDispatch(clientData, interp, objc-shift, objv+shift, cmd, object, cl, - methodName, frameType); - } + result = MethodDispatch(clientData, interp, objc-shift, objv+shift, cmd, object, cl, + methodName, frameType); /*fprintf(stderr, "MethodDispatch %s returns %d unknown %d\n", methodName, result, rst->unknown);*/ Index: generic/nsfInt.h =================================================================== diff -u -r3b36b2ecd2e684c57532cc5d79907fc99ed77ed2 -r51a8a78d1718e0335a692661f7d1d84f19ba0601 --- generic/nsfInt.h (.../nsfInt.h) (revision 3b36b2ecd2e684c57532cc5d79907fc99ed77ed2) +++ generic/nsfInt.h (.../nsfInt.h) (revision 51a8a78d1718e0335a692661f7d1d84f19ba0601) @@ -666,7 +666,6 @@ int overloadedMethods; long newCounter; NsfStringIncrStruct iss; - NsfObject *delegatee; Proc fakeProc; Tcl_Namespace *fakeNS; NsfStubs *nsfStubs;