summaryrefslogtreecommitdiffstats
path: root/generic/tclCompile.c
diff options
context:
space:
mode:
authordkf <donal.k.fellows@manchester.ac.uk>2004-09-29 22:17:28 (GMT)
committerdkf <donal.k.fellows@manchester.ac.uk>2004-09-29 22:17:28 (GMT)
commit1d5b0da0c8f65eeca48341adca32a96a8774f84a (patch)
tree9a574faca8ab395bddcb8ebbfcba24f070a7296a /generic/tclCompile.c
parente63ee140f8bf8b9c127ad90c03a516be076d6ae1 (diff)
downloadtcl-1d5b0da0c8f65eeca48341adca32a96a8774f84a.zip
tcl-1d5b0da0c8f65eeca48341adca32a96a8774f84a.tar.gz
tcl-1d5b0da0c8f65eeca48341adca32a96a8774f84a.tar.bz2
Factorize out the code for freeing an object's internal rep.
Diffstat (limited to 'generic/tclCompile.c')
-rw-r--r--generic/tclCompile.c7
1 files changed, 2 insertions, 5 deletions
diff --git a/generic/tclCompile.c b/generic/tclCompile.c
index 7b79e66..a262f34 100644
--- a/generic/tclCompile.c
+++ b/generic/tclCompile.c
@@ -11,7 +11,7 @@
* See the file "license.terms" for information on usage and redistribution
* of this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tclCompile.c,v 1.75 2004/09/26 16:36:04 msofer Exp $
+ * RCS: @(#) $Id: tclCompile.c,v 1.76 2004/09/29 22:17:31 dkf Exp $
*/
#include "tclInt.h"
@@ -1732,10 +1732,7 @@ TclInitByteCodeObj(objPtr, envPtr)
* compiled ByteCode.
*/
- if ((objPtr->typePtr != NULL) &&
- (objPtr->typePtr->freeIntRepProc != NULL)) {
- (*objPtr->typePtr->freeIntRepProc)(objPtr);
- }
+ TclFreeIntRep(objPtr);
objPtr->internalRep.otherValuePtr = (VOID *) codePtr;
objPtr->typePtr = &tclByteCodeType;
}