summaryrefslogtreecommitdiffstats
path: root/generic/tclInt.h
diff options
context:
space:
mode:
authordgp <dgp@users.sourceforge.net>2008-09-17 18:14:39 (GMT)
committerdgp <dgp@users.sourceforge.net>2008-09-17 18:14:39 (GMT)
commitde829f7b610dede86318f0a20d87aeaa55d20ffb (patch)
tree5996880bc2fc392bdc3fb4ac2b9778de9d45e301 /generic/tclInt.h
parent24857c216d0509db6addceb6d1caedfb84ee81ab (diff)
downloadtcl-de829f7b610dede86318f0a20d87aeaa55d20ffb.zip
tcl-de829f7b610dede86318f0a20d87aeaa55d20ffb.tar.gz
tcl-de829f7b610dede86318f0a20d87aeaa55d20ffb.tar.bz2
* generic/tclInt.h: Correct the TclGetLongFromObj,
TclGetIntFromObj, and TclGetIntForIndexM macros so that they retrieve the internalRep.longValue field instead of casting the internalRep.otherValuePtr field to type long.
Diffstat (limited to 'generic/tclInt.h')
-rw-r--r--generic/tclInt.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/generic/tclInt.h b/generic/tclInt.h
index bbbdf2f..f90b629 100644
--- a/generic/tclInt.h
+++ b/generic/tclInt.h
@@ -13,7 +13,7 @@
* See the file "license.terms" for information on usage and redistribution of
* this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tclInt.h,v 1.362.2.3 2008/07/22 21:41:13 andreas_kupries Exp $
+ * RCS: @(#) $Id: tclInt.h,v 1.362.2.4 2008/09/17 18:14:39 dgp Exp $
*/
#ifndef _TCLINT
@@ -2193,17 +2193,17 @@ typedef struct List {
#define TclGetLongFromObj(interp, objPtr, longPtr) \
(((objPtr)->typePtr == &tclIntType) \
- ? ((*(longPtr) = (long) (objPtr)->internalRep.otherValuePtr), TCL_OK) \
+ ? ((*(longPtr) = (objPtr)->internalRep.longValue), TCL_OK) \
: Tcl_GetLongFromObj((interp), (objPtr), (longPtr)))
#if (LONG_MAX == INT_MAX)
#define TclGetIntFromObj(interp, objPtr, intPtr) \
(((objPtr)->typePtr == &tclIntType) \
- ? ((*(intPtr) = (long) (objPtr)->internalRep.otherValuePtr), TCL_OK) \
+ ? ((*(intPtr) = (objPtr)->internalRep.longValue), TCL_OK) \
: Tcl_GetIntFromObj((interp), (objPtr), (intPtr)))
#define TclGetIntForIndexM(interp, objPtr, endValue, idxPtr) \
(((objPtr)->typePtr == &tclIntType) \
- ? ((*(idxPtr) = (long) (objPtr)->internalRep.otherValuePtr), TCL_OK) \
+ ? ((*(idxPtr) = (objPtr)->internalRep.longValue), TCL_OK) \
: TclGetIntForIndex((interp), (objPtr), (endValue), (idxPtr)))
#else
#define TclGetIntFromObj(interp, objPtr, intPtr) \