summaryrefslogtreecommitdiffstats
path: root/generic
diff options
context:
space:
mode:
authordgp <dgp@users.sourceforge.net>2001-09-27 20:32:35 (GMT)
committerdgp <dgp@users.sourceforge.net>2001-09-27 20:32:35 (GMT)
commit0d06e77cfc052c284f91df079e7010a5dddc2aa5 (patch)
tree588b769345699efc0e369fb5169a677a6d08c569 /generic
parent8005a1ea0359cc32b78d70f77f91fbc6e73e58b5 (diff)
downloadtcl-0d06e77cfc052c284f91df079e7010a5dddc2aa5.zip
tcl-0d06e77cfc052c284f91df079e7010a5dddc2aa5.tar.gz
tcl-0d06e77cfc052c284f91df079e7010a5dddc2aa5.tar.bz2
* Updated APIs in
generic/tclProc.c and generic/tclVar.c according to the guidelines of TIP 27. [Patch 465442]
Diffstat (limited to 'generic')
-rw-r--r--generic/tcl.decls10
-rw-r--r--generic/tclDecls.h15
-rw-r--r--generic/tclInt.decls7
-rw-r--r--generic/tclInt.h15
-rw-r--r--generic/tclIntDecls.h10
-rw-r--r--generic/tclProc.c6
-rw-r--r--generic/tclVar.c14
7 files changed, 33 insertions, 44 deletions
diff --git a/generic/tcl.decls b/generic/tcl.decls
index 62cc523..a391879 100644
--- a/generic/tcl.decls
+++ b/generic/tcl.decls
@@ -10,7 +10,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.decls,v 1.61 2001/09/27 00:19:57 dgp Exp $
+# RCS: @(#) $Id: tcl.decls,v 1.62 2001/09/27 20:32:35 dgp Exp $
library tcl
@@ -903,12 +903,12 @@ declare 257 generic {
void Tcl_UpdateLinkedVar(Tcl_Interp *interp, char *varName)
}
declare 258 generic {
- int Tcl_UpVar(Tcl_Interp *interp, char *frameName, char *varName, \
- char *localName, int flags)
+ int Tcl_UpVar(Tcl_Interp *interp, CONST char *frameName, char *varName, \
+ CONST char *localName, int flags)
}
declare 259 generic {
- int Tcl_UpVar2(Tcl_Interp *interp, char *frameName, char *part1, \
- char *part2, char *localName, int flags)
+ int Tcl_UpVar2(Tcl_Interp *interp, CONST char *frameName, char *part1, \
+ char *part2, CONST char *localName, int flags)
}
declare 260 generic {
int Tcl_VarEval(Tcl_Interp *interp, ...)
diff --git a/generic/tclDecls.h b/generic/tclDecls.h
index fe42b3b..c7621b4 100644
--- a/generic/tclDecls.h
+++ b/generic/tclDecls.h
@@ -8,7 +8,7 @@
* See the file "license.terms" for information on usage and redistribution
* of this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tclDecls.h,v 1.61 2001/09/27 00:19:57 dgp Exp $
+ * RCS: @(#) $Id: tclDecls.h,v 1.62 2001/09/27 20:32:35 dgp Exp $
*/
#ifndef _TCLDECLS
@@ -833,12 +833,13 @@ EXTERN void Tcl_UpdateLinkedVar _ANSI_ARGS_((Tcl_Interp * interp,
char * varName));
/* 258 */
EXTERN int Tcl_UpVar _ANSI_ARGS_((Tcl_Interp * interp,
- char * frameName, char * varName,
- char * localName, int flags));
+ CONST char * frameName, char * varName,
+ CONST char * localName, int flags));
/* 259 */
EXTERN int Tcl_UpVar2 _ANSI_ARGS_((Tcl_Interp * interp,
- char * frameName, char * part1, char * part2,
- char * localName, int flags));
+ CONST char * frameName, char * part1,
+ char * part2, CONST char * localName,
+ int flags));
/* 260 */
EXTERN int Tcl_VarEval _ANSI_ARGS_(TCL_VARARGS(Tcl_Interp *,interp));
/* 261 */
@@ -1822,8 +1823,8 @@ typedef struct TclStubs {
void (*tcl_UntraceVar) _ANSI_ARGS_((Tcl_Interp * interp, char * varName, int flags, Tcl_VarTraceProc * proc, ClientData clientData)); /* 255 */
void (*tcl_UntraceVar2) _ANSI_ARGS_((Tcl_Interp * interp, char * part1, char * part2, int flags, Tcl_VarTraceProc * proc, ClientData clientData)); /* 256 */
void (*tcl_UpdateLinkedVar) _ANSI_ARGS_((Tcl_Interp * interp, char * varName)); /* 257 */
- int (*tcl_UpVar) _ANSI_ARGS_((Tcl_Interp * interp, char * frameName, char * varName, char * localName, int flags)); /* 258 */
- int (*tcl_UpVar2) _ANSI_ARGS_((Tcl_Interp * interp, char * frameName, char * part1, char * part2, char * localName, int flags)); /* 259 */
+ int (*tcl_UpVar) _ANSI_ARGS_((Tcl_Interp * interp, CONST char * frameName, char * varName, CONST char * localName, int flags)); /* 258 */
+ int (*tcl_UpVar2) _ANSI_ARGS_((Tcl_Interp * interp, CONST char * frameName, char * part1, char * part2, CONST char * localName, int flags)); /* 259 */
int (*tcl_VarEval) _ANSI_ARGS_(TCL_VARARGS(Tcl_Interp *,interp)); /* 260 */
ClientData (*tcl_VarTraceInfo) _ANSI_ARGS_((Tcl_Interp * interp, char * varName, int flags, Tcl_VarTraceProc * procPtr, ClientData prevClientData)); /* 261 */
ClientData (*tcl_VarTraceInfo2) _ANSI_ARGS_((Tcl_Interp * interp, char * part1, char * part2, int flags, Tcl_VarTraceProc * procPtr, ClientData prevClientData)); /* 262 */
diff --git a/generic/tclInt.decls b/generic/tclInt.decls
index 39338cd..c179a9b 100644
--- a/generic/tclInt.decls
+++ b/generic/tclInt.decls
@@ -10,7 +10,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.decls,v 1.33 2001/09/25 16:23:56 dgp Exp $
+# RCS: @(#) $Id: tclInt.decls,v 1.34 2001/09/27 20:32:35 dgp Exp $
library tcl
@@ -109,7 +109,7 @@ declare 22 generic {
int *sizePtr, int *bracePtr)
}
declare 23 generic {
- Proc * TclFindProc(Interp *iPtr, char *procName)
+ Proc * TclFindProc(Interp *iPtr, CONST char *procName)
}
declare 24 generic {
int TclFormatInt(char *buffer, long n)
@@ -140,7 +140,8 @@ declare 31 generic {
char * TclGetExtension(char *name)
}
declare 32 generic {
- int TclGetFrame(Tcl_Interp *interp, char *str, CallFrame **framePtrPtr)
+ int TclGetFrame(Tcl_Interp *interp, CONST char *str, \
+ CallFrame **framePtrPtr)
}
declare 33 generic {
TclCmdProcType TclGetInterpProc(void)
diff --git a/generic/tclInt.h b/generic/tclInt.h
index 59cc000..bdb1f87 100644
--- a/generic/tclInt.h
+++ b/generic/tclInt.h
@@ -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: tclInt.h,v 1.66 2001/09/25 16:23:56 dgp Exp $
+ * RCS: @(#) $Id: tclInt.h,v 1.67 2001/09/27 20:32:35 dgp Exp $
*/
#ifndef _TCLINT
@@ -1672,8 +1672,6 @@ EXTERN void TclFinalizeAsync _ANSI_ARGS_((void));
EXTERN void TclFinalizeSynchronization _ANSI_ARGS_((void));
EXTERN void TclFinalizeThreadData _ANSI_ARGS_((void));
EXTERN void TclFindEncodings _ANSI_ARGS_((CONST char *argv0));
-EXTERN Proc * TclFindProc _ANSI_ARGS_((Interp *iPtr,
- char *procName));
EXTERN int TclFormatInt _ANSI_ARGS_((char *buffer, long n));
EXTERN void TclFreePackageInfo _ANSI_ARGS_((Interp *iPtr));
EXTERN int TclGetDate _ANSI_ARGS_((char *p,
@@ -1683,8 +1681,6 @@ EXTERN Tcl_Obj * TclGetElementOfIndexedArray _ANSI_ARGS_((
Tcl_Interp *interp, int localIndex,
Tcl_Obj *elemPtr, int flags));
EXTERN char * TclGetExtension _ANSI_ARGS_((char *name));
-EXTERN int TclGetFrame _ANSI_ARGS_((Tcl_Interp *interp,
- char *string, CallFrame **framePtrPtr));
EXTERN TclCmdProcType TclGetInterpProc _ANSI_ARGS_((void));
EXTERN int TclGetIntForIndex _ANSI_ARGS_((Tcl_Interp *interp,
Tcl_Obj *objPtr, int endValue, int *indexPtr));
@@ -1746,10 +1742,6 @@ EXTERN int TclIsLocalScalar _ANSI_ARGS_((CONST char *src,
EXTERN Proc * TclIsProc _ANSI_ARGS_((Command *cmdPtr));
EXTERN int TclJoinThread _ANSI_ARGS_((Tcl_ThreadId id,
int* result));
-EXTERN Var * TclLookupVar _ANSI_ARGS_((Tcl_Interp *interp,
- char *part1, char *part2, int flags, char *msg,
- int createPart1, int createPart2,
- Var **arrayPtrPtr));
EXTERN int TclMathInProgress _ANSI_ARGS_((void));
EXTERN Tcl_Obj * TclNewProcBodyObj _ANSI_ARGS_((Proc *procPtr));
EXTERN int TclObjCommandComplete _ANSI_ARGS_((Tcl_Obj *cmdPtr));
@@ -1855,9 +1847,6 @@ EXTERN void TclpSysFree _ANSI_ARGS_((VOID *ptr));
EXTERN VOID * TclpSysRealloc _ANSI_ARGS_((VOID *cp,
unsigned int size));
EXTERN void TclpUnloadFile _ANSI_ARGS_((ClientData clientData));
-EXTERN char * TclPrecTraceProc _ANSI_ARGS_((ClientData clientData,
- Tcl_Interp *interp, char *name1, char *name2,
- int flags));
EXTERN int TclPreventAliasLoop _ANSI_ARGS_((Tcl_Interp *interp,
Tcl_Interp *cmdInterp, Tcl_Command cmd));
EXTERN void TclProcCleanupProc _ANSI_ARGS_((Proc *procPtr));
@@ -1865,8 +1854,6 @@ EXTERN int TclProcCompileProc _ANSI_ARGS_((Tcl_Interp *interp,
Proc *procPtr, Tcl_Obj *bodyPtr, Namespace *nsPtr,
CONST char *description, CONST char *procName));
EXTERN void TclProcDeleteProc _ANSI_ARGS_((ClientData clientData));
-EXTERN int TclProcInterpProc _ANSI_ARGS_((ClientData clientData,
- Tcl_Interp *interp, int argc, char **argv));
EXTERN VOID * TclpThreadDataKeyGet _ANSI_ARGS_((
Tcl_ThreadDataKey *keyPtr));
EXTERN void TclpThreadDataKeyInit _ANSI_ARGS_((
diff --git a/generic/tclIntDecls.h b/generic/tclIntDecls.h
index dd0ab62..e470c1c 100644
--- a/generic/tclIntDecls.h
+++ b/generic/tclIntDecls.h
@@ -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: tclIntDecls.h,v 1.28 2001/09/25 16:23:56 dgp Exp $
+ * RCS: @(#) $Id: tclIntDecls.h,v 1.29 2001/09/27 20:32:35 dgp Exp $
*/
#ifndef _TCLINTDECLS
@@ -108,7 +108,7 @@ EXTERN int TclFindElement _ANSI_ARGS_((Tcl_Interp * interp,
int * bracePtr));
/* 23 */
EXTERN Proc * TclFindProc _ANSI_ARGS_((Interp * iPtr,
- char * procName));
+ CONST char * procName));
/* 24 */
EXTERN int TclFormatInt _ANSI_ARGS_((char * buffer, long n));
/* 25 */
@@ -128,7 +128,7 @@ EXTERN Tcl_Obj * TclGetElementOfIndexedArray _ANSI_ARGS_((
EXTERN char * TclGetExtension _ANSI_ARGS_((char * name));
/* 32 */
EXTERN int TclGetFrame _ANSI_ARGS_((Tcl_Interp * interp,
- char * str, CallFrame ** framePtrPtr));
+ CONST char * str, CallFrame ** framePtrPtr));
/* 33 */
EXTERN TclCmdProcType TclGetInterpProc _ANSI_ARGS_((void));
/* 34 */
@@ -533,7 +533,7 @@ typedef struct TclIntStubs {
void *reserved20;
void *reserved21;
int (*tclFindElement) _ANSI_ARGS_((Tcl_Interp * interp, CONST char * listStr, int listLength, CONST char ** elementPtr, CONST char ** nextPtr, int * sizePtr, int * bracePtr)); /* 22 */
- Proc * (*tclFindProc) _ANSI_ARGS_((Interp * iPtr, char * procName)); /* 23 */
+ Proc * (*tclFindProc) _ANSI_ARGS_((Interp * iPtr, CONST char * procName)); /* 23 */
int (*tclFormatInt) _ANSI_ARGS_((char * buffer, long n)); /* 24 */
void (*tclFreePackageInfo) _ANSI_ARGS_((Interp * iPtr)); /* 25 */
void *reserved26;
@@ -542,7 +542,7 @@ typedef struct TclIntStubs {
Tcl_Obj * (*tclGetElementOfIndexedArray) _ANSI_ARGS_((Tcl_Interp * interp, int localIndex, Tcl_Obj * elemPtr, int flags)); /* 29 */
void *reserved30;
char * (*tclGetExtension) _ANSI_ARGS_((char * name)); /* 31 */
- int (*tclGetFrame) _ANSI_ARGS_((Tcl_Interp * interp, char * str, CallFrame ** framePtrPtr)); /* 32 */
+ int (*tclGetFrame) _ANSI_ARGS_((Tcl_Interp * interp, CONST char * str, CallFrame ** framePtrPtr)); /* 32 */
TclCmdProcType (*tclGetInterpProc) _ANSI_ARGS_((void)); /* 33 */
int (*tclGetIntForIndex) _ANSI_ARGS_((Tcl_Interp * interp, Tcl_Obj * objPtr, int endValue, int * indexPtr)); /* 34 */
Tcl_Obj * (*tclGetIndexedScalar) _ANSI_ARGS_((Tcl_Interp * interp, int localIndex, int flags)); /* 35 */
diff --git a/generic/tclProc.c b/generic/tclProc.c
index d5b7cb3..f2efa09 100644
--- a/generic/tclProc.c
+++ b/generic/tclProc.c
@@ -10,7 +10,7 @@
* See the file "license.terms" for information on usage and redistribution
* of this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tclProc.c,v 1.28 2001/09/17 11:51:59 msofer Exp $
+ * RCS: @(#) $Id: tclProc.c,v 1.29 2001/09/27 20:32:35 dgp Exp $
*/
#include "tclInt.h"
@@ -545,7 +545,7 @@ procError:
int
TclGetFrame(interp, string, framePtrPtr)
Tcl_Interp *interp; /* Interpreter in which to find frame. */
- char *string; /* String describing frame. */
+ CONST char *string; /* String describing frame. */
CallFrame **framePtrPtr; /* Store pointer to frame here (or NULL
* if global frame indicated). */
{
@@ -717,7 +717,7 @@ Tcl_UplevelObjCmd(dummy, interp, objc, objv)
Proc *
TclFindProc(iPtr, procName)
Interp *iPtr; /* Interpreter in which to look. */
- char *procName; /* Name of desired procedure. */
+ CONST char *procName; /* Name of desired procedure. */
{
Tcl_Command cmd;
Tcl_Command origCmd;
diff --git a/generic/tclVar.c b/generic/tclVar.c
index 79e71c6..d3e2c4b 100644
--- a/generic/tclVar.c
+++ b/generic/tclVar.c
@@ -14,7 +14,7 @@
* See the file "license.terms" for information on usage and redistribution
* of this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tclVar.c,v 1.37 2001/09/25 14:34:53 msofer Exp $
+ * RCS: @(#) $Id: tclVar.c,v 1.38 2001/09/27 20:32:35 dgp Exp $
*/
#include "tclInt.h"
@@ -50,7 +50,7 @@ static void DeleteArray _ANSI_ARGS_((Interp *iPtr,
static int MakeUpvar _ANSI_ARGS_((
Interp *iPtr, CallFrame *framePtr,
char *otherP1, char *otherP2, int otherFlags,
- char *myName, int myFlags));
+ CONST char *myName, int myFlags));
static Var * NewVar _ANSI_ARGS_((void));
static ArraySearch * ParseSearchId _ANSI_ARGS_((Tcl_Interp *interp,
Var *varPtr, char *varName, Tcl_Obj *handleObj));
@@ -3605,7 +3605,7 @@ MakeUpvar(iPtr, framePtr, otherP1, otherP2, otherFlags, myName, myFlags)
char *otherP1, *otherP2; /* Two-part name of variable in framePtr. */
int otherFlags; /* 0, TCL_GLOBAL_ONLY or TCL_NAMESPACE_ONLY:
* indicates scope of "other" variable. */
- char *myName; /* Name of variable which will refer to
+ CONST char *myName; /* Name of variable which will refer to
* otherP1/otherP2. Must be a scalar. */
int myFlags; /* 0, TCL_GLOBAL_ONLY or TCL_NAMESPACE_ONLY:
* indicates scope of myName. */
@@ -3800,12 +3800,12 @@ int
Tcl_UpVar(interp, frameName, varName, localName, flags)
Tcl_Interp *interp; /* Command interpreter in which varName is
* to be looked up. */
- char *frameName; /* Name of the frame containing the source
+ CONST char *frameName; /* Name of the frame containing the source
* variable, such as "1" or "#0". */
char *varName; /* Name of a variable in interp to link to.
* May be either a scalar name or an
* element in an array. */
- char *localName; /* Name of link variable. */
+ CONST char *localName; /* Name of link variable. */
int flags; /* 0, TCL_GLOBAL_ONLY or TCL_NAMESPACE_ONLY:
* indicates scope of localName. */
{
@@ -3873,11 +3873,11 @@ int
Tcl_UpVar2(interp, frameName, part1, part2, localName, flags)
Tcl_Interp *interp; /* Interpreter containing variables. Used
* for error messages too. */
- char *frameName; /* Name of the frame containing the source
+ CONST char *frameName; /* Name of the frame containing the source
* variable, such as "1" or "#0". */
char *part1, *part2; /* Two parts of source variable name to
* link to. */
- char *localName; /* Name of link variable. */
+ CONST char *localName; /* Name of link variable. */
int flags; /* 0, TCL_GLOBAL_ONLY or TCL_NAMESPACE_ONLY:
* indicates scope of localName. */
{