diff options
Diffstat (limited to 'generic/tclOOCall.c')
-rw-r--r-- | generic/tclOOCall.c | 17 |
1 files changed, 8 insertions, 9 deletions
diff --git a/generic/tclOOCall.c b/generic/tclOOCall.c index e517d28..d4b1297 100644 --- a/generic/tclOOCall.c +++ b/generic/tclOOCall.c @@ -9,7 +9,7 @@ * See the file "license.terms" for information on usage and redistribution of * this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclOOCall.c,v 1.10 2008/07/18 23:29:44 msofer Exp $ + * RCS: @(#) $Id: tclOOCall.c,v 1.11 2008/09/25 10:13:30 dkf Exp $ */ #ifdef HAVE_CONFIG_H @@ -832,14 +832,17 @@ InitCallChain( Object *oPtr, int flags) { + callPtr->flags = flags & + (PUBLIC_METHOD | PRIVATE_METHOD | SPECIAL | FILTER_HANDLING); if (oPtr->flags & USE_CLASS_CACHE) { oPtr = oPtr->selfCls->thisPtr; + callPtr->flags |= USE_CLASS_CACHE; + } else { + callPtr->flags &= ~USE_CLASS_CACHE; } callPtr->epoch = oPtr->fPtr->epoch; callPtr->objectCreationEpoch = oPtr->creationEpoch; callPtr->objectEpoch = oPtr->epoch; - callPtr->flags = flags & - (PUBLIC_METHOD | PRIVATE_METHOD | SPECIAL | FILTER_HANDLING); callPtr->refCount = 1; callPtr->numChain = 0; callPtr->chain = callPtr->staticChain; @@ -869,12 +872,8 @@ IsStillValid( int mask) { if ((oPtr->flags & USE_CLASS_CACHE)) { - register Object *coPtr = oPtr->selfCls->thisPtr; - - return ((callPtr->objectCreationEpoch == coPtr->creationEpoch) - && (callPtr->epoch == coPtr->fPtr->epoch) - && (callPtr->objectEpoch == coPtr->epoch) - && ((callPtr->flags & mask) == (flags & mask))); + oPtr = oPtr->selfCls->thisPtr; + flags |= USE_CLASS_CACHE; } return ((callPtr->objectCreationEpoch == oPtr->creationEpoch) && (callPtr->epoch == oPtr->fPtr->epoch) |