summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--ChangeLog5
-rw-r--r--generic/tclObj.c14
2 files changed, 17 insertions, 2 deletions
diff --git a/ChangeLog b/ChangeLog
index 0c0df46..373efa4 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,10 @@
2006-03-02 Don Porter <dgp@users.sourceforge.net>
+ * generic/tclObj.c: Compatibility support for existing code that
+ calls Tcl_GetObjType("boolean").
+
+2006-03-02 Don Porter <dgp@users.sourceforge.net>
+
* generic/tclPathObj.c: Fix for failed normalization of
* tests/fileSystem.test: paths with /../ that lead back
to the root of the filesystem, like /foo/.. [Bug 1379287].
diff --git a/generic/tclObj.c b/generic/tclObj.c
index 5237cd4..559d717 100644
--- a/generic/tclObj.c
+++ b/generic/tclObj.c
@@ -12,7 +12,7 @@
* See the file "license.terms" for information on usage and redistribution of
* this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tclObj.c,v 1.103 2005/12/13 22:43:18 kennykb Exp $
+ * RCS: @(#) $Id: tclObj.c,v 1.104 2006/03/03 06:53:09 dgp Exp $
*/
#include "tclInt.h"
@@ -214,13 +214,20 @@ static int SetCmdNameFromAny(Tcl_Interp *interp, Tcl_Obj *objPtr);
* implementations.
*/
-Tcl_ObjType tclBooleanType = {
+Tcl_ObjType oldBooleanType = {
"boolean", /* name */
NULL, /* freeIntRepProc */
NULL, /* dupIntRepProc */
NULL, /* updateStringProc */
SetBooleanFromAny /* setFromAnyProc */
};
+Tcl_ObjType tclBooleanType = {
+ "booleanString", /* name */
+ NULL, /* freeIntRepProc */
+ NULL, /* dupIntRepProc */
+ NULL, /* updateStringProc */
+ SetBooleanFromAny /* setFromAnyProc */
+};
Tcl_ObjType tclDoubleType = {
"double", /* name */
NULL, /* freeIntRepProc */
@@ -363,6 +370,9 @@ TclInitObjSubsystem(void)
Tcl_RegisterObjType(&tclRegexpType);
Tcl_RegisterObjType(&tclProcBodyType);
+ /* For backward compatibility only ... */
+ Tcl_RegisterObjType(&oldBooleanType);
+
#ifdef TCL_COMPILE_STATS
Tcl_MutexLock(&tclObjMutex);
tclObjsAlloced = 0;