summaryrefslogtreecommitdiffstats
path: root/generic/tcl.h
diff options
context:
space:
mode:
authorstanton <stanton>1999-01-06 21:08:50 (GMT)
committerstanton <stanton>1999-01-06 21:08:50 (GMT)
commitebe914ee21917bcea0864713fb1d2b3eade80686 (patch)
treea2f2efdbc635d80f21f222e0b00d31a2dad086fd /generic/tcl.h
parent83b3538905ea600cb46f51d49dbeb69d2f6af310 (diff)
downloadtcl-ebe914ee21917bcea0864713fb1d2b3eade80686.zip
tcl-ebe914ee21917bcea0864713fb1d2b3eade80686.tar.gz
tcl-ebe914ee21917bcea0864713fb1d2b3eade80686.tar.bz2
* win/makefile.vc:
* generic/tcl.h: * generic/tclAlloc.c: Added USE_NATIVEMALLOC ifdefs to make it easier to compile for use with Purify.
Diffstat (limited to 'generic/tcl.h')
-rw-r--r--generic/tcl.h16
1 files changed, 15 insertions, 1 deletions
diff --git a/generic/tcl.h b/generic/tcl.h
index a12be09..404c89e 100644
--- a/generic/tcl.h
+++ b/generic/tcl.h
@@ -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: tcl.h,v 1.31 1999/01/05 01:18:34 rjohnson Exp $
+ * RCS: @(#) $Id: tcl.h,v 1.32 1999/01/06 21:08:50 stanton Exp $
*/
#ifndef _TCL
@@ -71,6 +71,12 @@
# ifndef USE_PROTOTYPE
# define USE_PROTOTYPE 1
# endif
+
+/*
+ * Under Windows we need to call Tcl_Alloc in all cases to avoid competing
+ * C run-time library issues.
+ */
+
# ifndef USE_TCLALLOC
# define USE_TCLALLOC 1
# endif
@@ -743,6 +749,14 @@ EXTERN void Tcl_ValidateAllMemory _ANSI_ARGS_((char *file,
#else
+/*
+ * If USE_TCLALLOC is true, then we need to call Tcl_Alloc instead of
+ * the native malloc/free. The only time USE_TCLALLOC should not be
+ * true is when compiling the Tcl/Tk libraries on Unix systems. In this
+ * case we can safely call the native malloc/free directly as a performance
+ * optimization.
+ */
+
# if USE_TCLALLOC
# define ckalloc(x) Tcl_Alloc(x)
# define ckfree(x) Tcl_Free(x)