diff options
author | dgp <dgp@users.sourceforge.net> | 2002-01-16 06:02:33 (GMT) |
---|---|---|
committer | dgp <dgp@users.sourceforge.net> | 2002-01-16 06:02:33 (GMT) |
commit | 265ce643df6d23c8b73644d64e926d5bba4278f3 (patch) | |
tree | 0cb32a1332282c8b6037986a78eae653a622cf18 | |
parent | 14ca3bb7f42dde3399d6968c2c62597320f9a9dc (diff) | |
download | tcl-265ce643df6d23c8b73644d64e926d5bba4278f3.zip tcl-265ce643df6d23c8b73644d64e926d5bba4278f3.tar.gz tcl-265ce643df6d23c8b73644d64e926d5bba4278f3.tar.bz2 |
* Updated APIs in generic/tclHistory.c according to the guidelines
of TIP 27.
* Updated APIs in generic/tclInterp.c according to the guidelines of
TIP 27.
***POTENTIAL INCOMPATIBILITY***
Includes a source incompatibility in the targetCmdPtr arguments of
the Tcl_GetAlias* routines.
-rw-r--r-- | ChangeLog | 20 | ||||
-rw-r--r-- | doc/CrtSlave.3 | 24 | ||||
-rw-r--r-- | doc/RecordEval.3 | 4 | ||||
-rw-r--r-- | generic/tcl.decls | 29 | ||||
-rw-r--r-- | generic/tclDecls.h | 39 | ||||
-rw-r--r-- | generic/tclHistory.c | 4 | ||||
-rw-r--r-- | generic/tclInterp.c | 26 |
7 files changed, 84 insertions, 62 deletions
@@ -1,3 +1,23 @@ +2002-01-16 Don Porter <dgp@users.sourceforge.net> + + * generic/tcl.decls (Tcl_RecordAndEval): + * generic/tclDecls.h: make genstubs + * generic/tclHistory.c (Tcl_RecordAndEval): Updated APIs in + generic/tclHistory.c according to the guidelines of TIP 27. + + * doc/CrtSlave.3: + * generic/tcl.decls (Tcl_CreateAlias, Tcl_CreateAliasObj, + Tcl_CreateSlave, Tcl_GetAlias, Tcl_GetAliasObj, Tcl_GetSlave): + * generic/tclInterp.c (Tcl_CreateAlias, Tcl_CreateAliasObj, + Tcl_CreateSlave, Tcl_GetAlias, Tcl_GetAliasObj, Tcl_GetSlave): + Updated APIs in the file generic/tclInterp.c according to the + guidelines of TIP 27. + ***POTENTIAL INCOMPATIBILITY*** + Includes a source incompatibility in the targetCmdPtr arguments of + the Tcl_GetAlias* routines. + + * generic/tclDecls.h: make genstubs + 2002-01-15 Don Porter <dgp@users.sourceforge.net> * doc/SetErrno.3 (Tcl_ErrnoMsg): Corrected documentation for diff --git a/doc/CrtSlave.3 b/doc/CrtSlave.3 index 9cd5bde..4da8477 100644 --- a/doc/CrtSlave.3 +++ b/doc/CrtSlave.3 @@ -4,7 +4,7 @@ '\" See the file "license.terms" for information on usage and redistribution '\" of this file, and for a DISCLAIMER OF ALL WARRANTIES. '\" -'\" RCS: @(#) $Id: CrtSlave.3,v 1.5 2001/04/24 20:59:17 kennykb Exp $ +'\" RCS: @(#) $Id: CrtSlave.3,v 1.6 2002/01/16 06:02:33 dgp Exp $ '\" .so man.macros .TH Tcl_CreateSlave 3 7.6 Tcl "Tcl Library Procedures" @@ -35,18 +35,18 @@ int .sp .VS int -\fBTcl_CreateAlias\fR(\fIslaveInterp, srcCmd, targetInterp, targetCmd, argc, argv\fR) +\fBTcl_CreateAlias\fR(\fIslaveInterp, slaveCmd, targetInterp, targetCmd, argc, argv\fR) .sp int -\fBTcl_CreateAliasObj\fR(\fIslaveInterp, srcCmd, targetInterp, targetCmd, objc, objv\fR) +\fBTcl_CreateAliasObj\fR(\fIslaveInterp, slaveCmd, targetInterp, targetCmd, objc, objv\fR) .VE .sp int -\fBTcl_GetAlias\fR(\fIinterp, srcCmd, targetInterpPtr, targetCmdPtr, argcPtr, argvPtr\fR) +\fBTcl_GetAlias\fR(\fIinterp, slaveCmd, targetInterpPtr, targetCmdPtr, argcPtr, argvPtr\fR) .sp .VS int -\fBTcl_GetAliasObj\fR(\fIinterp, srcCmd, targetInterpPtr, targetCmdPtr, objcPtr, objvPtr\fR) +\fBTcl_GetAliasObj\fR(\fIinterp, slaveCmd, targetInterpPtr, targetCmdPtr, objcPtr, objvPtr\fR) .sp int \fBTcl_ExposeCommand\fR(\fIinterp, hiddenCmdName, cmdName\fR) @@ -57,7 +57,7 @@ int .AS Tcl_InterpDeleteProc **hiddenCmdName .AP Tcl_Interp *interp in Interpreter in which to execute the specified command. -.AP char *slaveName in +.AP "CONST char" *slaveName in Name of slave interpreter to create or manipulate. .AP int isSafe in If non-zero, a ``safe'' slave that is suitable for running untrusted code @@ -65,15 +65,15 @@ is created, otherwise a trusted slave is created. .AP Tcl_Interp *slaveInterp in Interpreter to use for creating the source command for an alias (see below). -.AP char *srcCmd in +.AP "CONST char" *slaveCmd in Name of source command for alias. .AP Tcl_Interp *targetInterp in Interpreter that contains the target command for an alias. -.AP char *targetCmd in +.AP "CONST char" *targetCmd in Name of target command for alias in \fItargetInterp\fR. .AP int argc in Count of additional arguments to pass to the alias command. -.AP char **argv in +.AP "char * CONST" *argv in Vector of strings, the additional arguments to pass to the alias command. This storage is owned by the caller. .AP int objc in @@ -85,7 +85,7 @@ This storage is owned by the caller. .AP Tcl_Interp **targetInterpPtr in Pointer to location to store the address of the interpreter where a target command is defined for an alias. -.AP char **targetCmdPtr out +.AP "CONST char" **targetCmdPtr out Pointer to location to store the address of the name of the target command for an alias. .AP int *argcPtr out @@ -161,11 +161,11 @@ of the relative path succeeds, \fBTCL_OK\fR is returned, else \fIaskingInterp\fR contains the error message. .PP .VS -\fBTcl_CreateAlias\fR creates an object command named \fIsrcCmd\fR in +\fBTcl_CreateAlias\fR creates an object command named \fIslaveCmd\fR in \fIslaveInterp\fR that when invoked, will cause the command \fItargetCmd\fR to be invoked in \fItargetInterp\fR. The arguments specified by the strings contained in \fIargv\fR are always prepended to any arguments supplied in the -invocation of \fIsrcCmd\fR and passed to \fItargetCmd\fR. +invocation of \fIslaveCmd\fR and passed to \fItargetCmd\fR. This operation returns \fBTCL_OK\fR if it succeeds, or \fBTCL_ERROR\fR if it fails; in that case, an error message is left in the object result of \fIslaveInterp\fR. diff --git a/doc/RecordEval.3 b/doc/RecordEval.3 index 7621b6d..ebc726c 100644 --- a/doc/RecordEval.3 +++ b/doc/RecordEval.3 @@ -5,7 +5,7 @@ '\" See the file "license.terms" for information on usage and redistribution '\" of this file, and for a DISCLAIMER OF ALL WARRANTIES. '\" -'\" RCS: @(#) $Id: RecordEval.3,v 1.3 2000/04/14 23:01:53 hobbs Exp $ +'\" RCS: @(#) $Id: RecordEval.3,v 1.4 2002/01/16 06:02:33 dgp Exp $ '\" .so man.macros .TH Tcl_RecordAndEval 3 7.4 Tcl "Tcl Library Procedures" @@ -22,7 +22,7 @@ int .AS Tcl_Interp *interp; .AP Tcl_Interp *interp in Tcl interpreter in which to evaluate command. -.AP char *cmd in +.AP "CONST char" *cmd in Command (or sequence of commands) to execute. .AP int flags in An OR'ed combination of flag bits. TCL_NO_EVAL means record the diff --git a/generic/tcl.decls b/generic/tcl.decls index db6a7ed..d64952e 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.71 2002/01/15 21:19:06 dgp Exp $ +# RCS: @(#) $Id: tcl.decls,v 1.72 2002/01/16 06:02:33 dgp Exp $ library tcl @@ -316,12 +316,13 @@ declare 85 generic { int flags) } declare 86 generic { - int Tcl_CreateAlias(Tcl_Interp *slave, char *slaveCmd, \ - Tcl_Interp *target, char *targetCmd, int argc, char **argv) + int Tcl_CreateAlias(Tcl_Interp *slave, CONST char *slaveCmd, \ + Tcl_Interp *target, CONST char *targetCmd, int argc, \ + char * CONST *argv) } declare 87 generic { - int Tcl_CreateAliasObj(Tcl_Interp *slave, char *slaveCmd, \ - Tcl_Interp *target, char *targetCmd, int objc, \ + int Tcl_CreateAliasObj(Tcl_Interp *slave, CONST char *slaveCmd, \ + Tcl_Interp *target, CONST char *targetCmd, int objc, \ Tcl_Obj *CONST objv[]) } declare 88 generic { @@ -363,7 +364,7 @@ declare 96 generic { Tcl_CmdDeleteProc *deleteProc) } declare 97 generic { - Tcl_Interp * Tcl_CreateSlave(Tcl_Interp *interp, char *slaveName, \ + Tcl_Interp * Tcl_CreateSlave(Tcl_Interp *interp, CONST char *slaveName, \ int isSafe) } declare 98 generic { @@ -529,14 +530,14 @@ declare 147 generic { void Tcl_FreeResult(Tcl_Interp *interp) } declare 148 generic { - int Tcl_GetAlias(Tcl_Interp *interp, char *slaveCmd, \ - Tcl_Interp **targetInterpPtr, char **targetCmdPtr, int *argcPtr, \ - char ***argvPtr) + int Tcl_GetAlias(Tcl_Interp *interp, CONST char *slaveCmd, \ + Tcl_Interp **targetInterpPtr, CONST char **targetCmdPtr, \ + int *argcPtr, char ***argvPtr) } declare 149 generic { - int Tcl_GetAliasObj(Tcl_Interp *interp, char *slaveCmd, \ - Tcl_Interp **targetInterpPtr, char **targetCmdPtr, int *objcPtr, \ - Tcl_Obj ***objv) + int Tcl_GetAliasObj(Tcl_Interp *interp, CONST char *slaveCmd, \ + Tcl_Interp **targetInterpPtr, CONST char **targetCmdPtr, \ + int *objcPtr, Tcl_Obj ***objv) } declare 150 generic { ClientData Tcl_GetAssocData(Tcl_Interp *interp, CONST char *name, \ @@ -617,7 +618,7 @@ declare 171 generic { int Tcl_GetServiceMode(void) } declare 172 generic { - Tcl_Interp * Tcl_GetSlave(Tcl_Interp *interp, char *slaveName) + Tcl_Interp * Tcl_GetSlave(Tcl_Interp *interp, CONST char *slaveName) } declare 173 generic { Tcl_Channel Tcl_GetStdChannel(int type) @@ -737,7 +738,7 @@ declare 207 {unix win} { void Tcl_ReapDetachedProcs(void) } declare 208 generic { - int Tcl_RecordAndEval(Tcl_Interp *interp, char *cmd, int flags) + int Tcl_RecordAndEval(Tcl_Interp *interp, CONST char *cmd, int flags) } declare 209 generic { int Tcl_RecordAndEvalObj(Tcl_Interp *interp, Tcl_Obj *cmdPtr, int flags) diff --git a/generic/tclDecls.h b/generic/tclDecls.h index c65f298..b3869b9 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.71 2002/01/15 21:19:07 dgp Exp $ + * RCS: @(#) $Id: tclDecls.h,v 1.72 2002/01/16 06:02:34 dgp Exp $ */ #ifndef _TCLDECLS @@ -284,12 +284,13 @@ EXTERN int Tcl_ConvertCountedElement _ANSI_ARGS_(( int flags)); /* 86 */ EXTERN int Tcl_CreateAlias _ANSI_ARGS_((Tcl_Interp * slave, - char * slaveCmd, Tcl_Interp * target, - char * targetCmd, int argc, char ** argv)); + CONST char * slaveCmd, Tcl_Interp * target, + CONST char * targetCmd, int argc, + char * CONST * argv)); /* 87 */ EXTERN int Tcl_CreateAliasObj _ANSI_ARGS_((Tcl_Interp * slave, - char * slaveCmd, Tcl_Interp * target, - char * targetCmd, int objc, + CONST char * slaveCmd, Tcl_Interp * target, + CONST char * targetCmd, int objc, Tcl_Obj *CONST objv[])); /* 88 */ EXTERN Tcl_Channel Tcl_CreateChannel _ANSI_ARGS_(( @@ -331,7 +332,7 @@ EXTERN Tcl_Command Tcl_CreateObjCommand _ANSI_ARGS_(( Tcl_CmdDeleteProc * deleteProc)); /* 97 */ EXTERN Tcl_Interp * Tcl_CreateSlave _ANSI_ARGS_((Tcl_Interp * interp, - char * slaveName, int isSafe)); + CONST char * slaveName, int isSafe)); /* 98 */ EXTERN Tcl_TimerToken Tcl_CreateTimerHandler _ANSI_ARGS_((int milliseconds, Tcl_TimerProc * proc, ClientData clientData)); @@ -489,15 +490,15 @@ EXTERN int Tcl_Flush _ANSI_ARGS_((Tcl_Channel chan)); EXTERN void Tcl_FreeResult _ANSI_ARGS_((Tcl_Interp * interp)); /* 148 */ EXTERN int Tcl_GetAlias _ANSI_ARGS_((Tcl_Interp * interp, - char * slaveCmd, + CONST char * slaveCmd, Tcl_Interp ** targetInterpPtr, - char ** targetCmdPtr, int * argcPtr, + CONST char ** targetCmdPtr, int * argcPtr, char *** argvPtr)); /* 149 */ EXTERN int Tcl_GetAliasObj _ANSI_ARGS_((Tcl_Interp * interp, - char * slaveCmd, + CONST char * slaveCmd, Tcl_Interp ** targetInterpPtr, - char ** targetCmdPtr, int * objcPtr, + CONST char ** targetCmdPtr, int * objcPtr, Tcl_Obj *** objv)); /* 150 */ EXTERN ClientData Tcl_GetAssocData _ANSI_ARGS_((Tcl_Interp * interp, @@ -563,7 +564,7 @@ EXTERN int Tcl_GetsObj _ANSI_ARGS_((Tcl_Channel chan, EXTERN int Tcl_GetServiceMode _ANSI_ARGS_((void)); /* 172 */ EXTERN Tcl_Interp * Tcl_GetSlave _ANSI_ARGS_((Tcl_Interp * interp, - char * slaveName)); + CONST char * slaveName)); /* 173 */ EXTERN Tcl_Channel Tcl_GetStdChannel _ANSI_ARGS_((int type)); /* 174 */ @@ -678,7 +679,7 @@ EXTERN void Tcl_ReapDetachedProcs _ANSI_ARGS_((void)); #endif /* __WIN32__ */ /* 208 */ EXTERN int Tcl_RecordAndEval _ANSI_ARGS_((Tcl_Interp * interp, - char * cmd, int flags)); + CONST char * cmd, int flags)); /* 209 */ EXTERN int Tcl_RecordAndEvalObj _ANSI_ARGS_(( Tcl_Interp * interp, Tcl_Obj * cmdPtr, @@ -1625,8 +1626,8 @@ typedef struct TclStubs { char * (*tcl_Concat) _ANSI_ARGS_((int argc, char * CONST * argv)); /* 83 */ int (*tcl_ConvertElement) _ANSI_ARGS_((CONST char * src, char * dst, int flags)); /* 84 */ int (*tcl_ConvertCountedElement) _ANSI_ARGS_((CONST char * src, int length, char * dst, int flags)); /* 85 */ - int (*tcl_CreateAlias) _ANSI_ARGS_((Tcl_Interp * slave, char * slaveCmd, Tcl_Interp * target, char * targetCmd, int argc, char ** argv)); /* 86 */ - int (*tcl_CreateAliasObj) _ANSI_ARGS_((Tcl_Interp * slave, char * slaveCmd, Tcl_Interp * target, char * targetCmd, int objc, Tcl_Obj *CONST objv[])); /* 87 */ + int (*tcl_CreateAlias) _ANSI_ARGS_((Tcl_Interp * slave, CONST char * slaveCmd, Tcl_Interp * target, CONST char * targetCmd, int argc, char * CONST * argv)); /* 86 */ + int (*tcl_CreateAliasObj) _ANSI_ARGS_((Tcl_Interp * slave, CONST char * slaveCmd, Tcl_Interp * target, CONST char * targetCmd, int objc, Tcl_Obj *CONST objv[])); /* 87 */ Tcl_Channel (*tcl_CreateChannel) _ANSI_ARGS_((Tcl_ChannelType * typePtr, CONST char * chanName, ClientData instanceData, int mask)); /* 88 */ void (*tcl_CreateChannelHandler) _ANSI_ARGS_((Tcl_Channel chan, int mask, Tcl_ChannelProc * proc, ClientData clientData)); /* 89 */ void (*tcl_CreateCloseHandler) _ANSI_ARGS_((Tcl_Channel chan, Tcl_CloseProc * proc, ClientData clientData)); /* 90 */ @@ -1636,7 +1637,7 @@ typedef struct TclStubs { Tcl_Interp * (*tcl_CreateInterp) _ANSI_ARGS_((void)); /* 94 */ void (*tcl_CreateMathFunc) _ANSI_ARGS_((Tcl_Interp * interp, CONST char * name, int numArgs, Tcl_ValueType * argTypes, Tcl_MathProc * proc, ClientData clientData)); /* 95 */ Tcl_Command (*tcl_CreateObjCommand) _ANSI_ARGS_((Tcl_Interp * interp, CONST char * cmdName, Tcl_ObjCmdProc * proc, ClientData clientData, Tcl_CmdDeleteProc * deleteProc)); /* 96 */ - Tcl_Interp * (*tcl_CreateSlave) _ANSI_ARGS_((Tcl_Interp * interp, char * slaveName, int isSafe)); /* 97 */ + Tcl_Interp * (*tcl_CreateSlave) _ANSI_ARGS_((Tcl_Interp * interp, CONST char * slaveName, int isSafe)); /* 97 */ Tcl_TimerToken (*tcl_CreateTimerHandler) _ANSI_ARGS_((int milliseconds, Tcl_TimerProc * proc, ClientData clientData)); /* 98 */ Tcl_Trace (*tcl_CreateTrace) _ANSI_ARGS_((Tcl_Interp * interp, int level, Tcl_CmdTraceProc * proc, ClientData clientData)); /* 99 */ void (*tcl_DeleteAssocData) _ANSI_ARGS_((Tcl_Interp * interp, CONST char * name)); /* 100 */ @@ -1695,8 +1696,8 @@ typedef struct TclStubs { Tcl_HashEntry * (*tcl_FirstHashEntry) _ANSI_ARGS_((Tcl_HashTable * tablePtr, Tcl_HashSearch * searchPtr)); /* 145 */ int (*tcl_Flush) _ANSI_ARGS_((Tcl_Channel chan)); /* 146 */ void (*tcl_FreeResult) _ANSI_ARGS_((Tcl_Interp * interp)); /* 147 */ - int (*tcl_GetAlias) _ANSI_ARGS_((Tcl_Interp * interp, char * slaveCmd, Tcl_Interp ** targetInterpPtr, char ** targetCmdPtr, int * argcPtr, char *** argvPtr)); /* 148 */ - int (*tcl_GetAliasObj) _ANSI_ARGS_((Tcl_Interp * interp, char * slaveCmd, Tcl_Interp ** targetInterpPtr, char ** targetCmdPtr, int * objcPtr, Tcl_Obj *** objv)); /* 149 */ + int (*tcl_GetAlias) _ANSI_ARGS_((Tcl_Interp * interp, CONST char * slaveCmd, Tcl_Interp ** targetInterpPtr, CONST char ** targetCmdPtr, int * argcPtr, char *** argvPtr)); /* 148 */ + int (*tcl_GetAliasObj) _ANSI_ARGS_((Tcl_Interp * interp, CONST char * slaveCmd, Tcl_Interp ** targetInterpPtr, CONST char ** targetCmdPtr, int * objcPtr, Tcl_Obj *** objv)); /* 149 */ ClientData (*tcl_GetAssocData) _ANSI_ARGS_((Tcl_Interp * interp, CONST char * name, Tcl_InterpDeleteProc ** procPtr)); /* 150 */ Tcl_Channel (*tcl_GetChannel) _ANSI_ARGS_((Tcl_Interp * interp, CONST char * chanName, int * modePtr)); /* 151 */ int (*tcl_GetChannelBufferSize) _ANSI_ARGS_((Tcl_Channel chan)); /* 152 */ @@ -1727,7 +1728,7 @@ typedef struct TclStubs { int (*tcl_Gets) _ANSI_ARGS_((Tcl_Channel chan, Tcl_DString * dsPtr)); /* 169 */ int (*tcl_GetsObj) _ANSI_ARGS_((Tcl_Channel chan, Tcl_Obj * objPtr)); /* 170 */ int (*tcl_GetServiceMode) _ANSI_ARGS_((void)); /* 171 */ - Tcl_Interp * (*tcl_GetSlave) _ANSI_ARGS_((Tcl_Interp * interp, char * slaveName)); /* 172 */ + Tcl_Interp * (*tcl_GetSlave) _ANSI_ARGS_((Tcl_Interp * interp, CONST char * slaveName)); /* 172 */ Tcl_Channel (*tcl_GetStdChannel) _ANSI_ARGS_((int type)); /* 173 */ char * (*tcl_GetStringResult) _ANSI_ARGS_((Tcl_Interp * interp)); /* 174 */ char * (*tcl_GetVar) _ANSI_ARGS_((Tcl_Interp * interp, char * varName, int flags)); /* 175 */ @@ -1779,7 +1780,7 @@ typedef struct TclStubs { #ifdef MAC_TCL void *reserved207; #endif /* MAC_TCL */ - int (*tcl_RecordAndEval) _ANSI_ARGS_((Tcl_Interp * interp, char * cmd, int flags)); /* 208 */ + int (*tcl_RecordAndEval) _ANSI_ARGS_((Tcl_Interp * interp, CONST char * cmd, int flags)); /* 208 */ int (*tcl_RecordAndEvalObj) _ANSI_ARGS_((Tcl_Interp * interp, Tcl_Obj * cmdPtr, int flags)); /* 209 */ void (*tcl_RegisterChannel) _ANSI_ARGS_((Tcl_Interp * interp, Tcl_Channel chan)); /* 210 */ void (*tcl_RegisterObjType) _ANSI_ARGS_((Tcl_ObjType * typePtr)); /* 211 */ diff --git a/generic/tclHistory.c b/generic/tclHistory.c index 5f2a9f2..20ccb7c 100644 --- a/generic/tclHistory.c +++ b/generic/tclHistory.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: tclHistory.c,v 1.3 1999/04/16 00:46:47 stanton Exp $ + * RCS: @(#) $Id: tclHistory.c,v 1.4 2002/01/16 06:02:34 dgp Exp $ */ #include "tclInt.h" @@ -42,7 +42,7 @@ int Tcl_RecordAndEval(interp, cmd, flags) Tcl_Interp *interp; /* Token for interpreter in which command * will be executed. */ - char *cmd; /* Command to record. */ + CONST char *cmd; /* Command to record. */ int flags; /* Additional flags. TCL_NO_EVAL means * only record: don't execute command. * TCL_EVAL_GLOBAL means use Tcl_GlobalEval diff --git a/generic/tclInterp.c b/generic/tclInterp.c index e6e7ca6..d28758d 100644 --- a/generic/tclInterp.c +++ b/generic/tclInterp.c @@ -9,7 +9,7 @@ * See the file "license.terms" for information on usage and redistribution * of this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclInterp.c,v 1.8 2001/11/16 22:28:08 hobbs Exp $ + * RCS: @(#) $Id: tclInterp.c,v 1.9 2002/01/16 06:02:34 dgp Exp $ */ #include <stdio.h> @@ -808,11 +808,11 @@ GetInterp2(interp, objc, objv) int Tcl_CreateAlias(slaveInterp, slaveCmd, targetInterp, targetCmd, argc, argv) Tcl_Interp *slaveInterp; /* Interpreter for source command. */ - char *slaveCmd; /* Command to install in slave. */ + CONST char *slaveCmd; /* Command to install in slave. */ Tcl_Interp *targetInterp; /* Interpreter for target command. */ - char *targetCmd; /* Name of target command. */ + CONST char *targetCmd; /* Name of target command. */ int argc; /* How many additional arguments? */ - char **argv; /* These are the additional args. */ + char * CONST *argv; /* These are the additional args. */ { Tcl_Obj *slaveObjPtr, *targetObjPtr; Tcl_Obj **objv; @@ -863,9 +863,9 @@ Tcl_CreateAlias(slaveInterp, slaveCmd, targetInterp, targetCmd, argc, argv) int Tcl_CreateAliasObj(slaveInterp, slaveCmd, targetInterp, targetCmd, objc, objv) Tcl_Interp *slaveInterp; /* Interpreter for source command. */ - char *slaveCmd; /* Command to install in slave. */ + CONST char *slaveCmd; /* Command to install in slave. */ Tcl_Interp *targetInterp; /* Interpreter for target command. */ - char *targetCmd; /* Name of target command. */ + CONST char *targetCmd; /* Name of target command. */ int objc; /* How many additional arguments? */ Tcl_Obj *CONST objv[]; /* Argument vector. */ { @@ -906,9 +906,9 @@ int Tcl_GetAlias(interp, aliasName, targetInterpPtr, targetNamePtr, argcPtr, argvPtr) Tcl_Interp *interp; /* Interp to start search from. */ - char *aliasName; /* Name of alias to find. */ + CONST char *aliasName; /* Name of alias to find. */ Tcl_Interp **targetInterpPtr; /* (Return) target interpreter. */ - char **targetNamePtr; /* (Return) name of target command. */ + CONST char **targetNamePtr; /* (Return) name of target command. */ int *argcPtr; /* (Return) count of addnl args. */ char ***argvPtr; /* (Return) additional arguments. */ { @@ -966,9 +966,9 @@ int Tcl_GetAliasObj(interp, aliasName, targetInterpPtr, targetNamePtr, objcPtr, objvPtr) Tcl_Interp *interp; /* Interp to start search from. */ - char *aliasName; /* Name of alias to find. */ + CONST char *aliasName; /* Name of alias to find. */ Tcl_Interp **targetInterpPtr; /* (Return) target interpreter. */ - char **targetNamePtr; /* (Return) name of target command. */ + CONST char **targetNamePtr; /* (Return) name of target command. */ int *objcPtr; /* (Return) count of addnl args. */ Tcl_Obj ***objvPtr; /* (Return) additional args. */ { @@ -991,7 +991,7 @@ Tcl_GetAliasObj(interp, aliasName, targetInterpPtr, targetNamePtr, objcPtr, if (targetInterpPtr != (Tcl_Interp **) NULL) { *targetInterpPtr = aliasPtr->targetInterp; } - if (targetNamePtr != (char **) NULL) { + if (targetNamePtr != (CONST char **) NULL) { *targetNamePtr = Tcl_GetString(objv[0]); } if (objcPtr != (int *) NULL) { @@ -1525,7 +1525,7 @@ AliasObjCmdDeleteProc(clientData) Tcl_Interp * Tcl_CreateSlave(interp, slavePath, isSafe) Tcl_Interp *interp; /* Interpreter to start search at. */ - char *slavePath; /* Name of slave to create. */ + CONST char *slavePath; /* Name of slave to create. */ int isSafe; /* Should new slave be "safe" ? */ { Tcl_Obj *pathPtr; @@ -1558,7 +1558,7 @@ Tcl_CreateSlave(interp, slavePath, isSafe) Tcl_Interp * Tcl_GetSlave(interp, slavePath) Tcl_Interp *interp; /* Interpreter to start search from. */ - char *slavePath; /* Path of slave to find. */ + CONST char *slavePath; /* Path of slave to find. */ { Tcl_Obj *pathPtr; Tcl_Interp *slaveInterp; |