diff options
-rw-r--r-- | doc/ChnlStack.3 | 4 | ||||
-rw-r--r-- | doc/CrtChannel.3 | 10 | ||||
-rw-r--r-- | generic/tcl.decls | 11 | ||||
-rw-r--r-- | generic/tcl.h | 4 | ||||
-rw-r--r-- | generic/tclDecls.h | 14 | ||||
-rw-r--r-- | generic/tclIO.c | 10 | ||||
-rw-r--r-- | generic/tclIO.h | 4 |
7 files changed, 29 insertions, 28 deletions
diff --git a/doc/ChnlStack.3 b/doc/ChnlStack.3 index 092ead5..be22a88 100644 --- a/doc/ChnlStack.3 +++ b/doc/ChnlStack.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: ChnlStack.3,v 1.8 2006/11/15 09:23:01 dkf Exp $ +'\" RCS: @(#) $Id: ChnlStack.3,v 1.9 2008/10/04 12:33:34 nijtmans Exp $ .so man.macros .TH Tcl_StackChannel 3 8.3 Tcl "Tcl Library Procedures" .BS @@ -32,7 +32,7 @@ Tcl_Channel .AS Tcl_ChannelType clientData .AP Tcl_Interp *interp in Interpreter for error reporting. -.AP Tcl_ChannelType *typePtr in +.AP "const Tcl_ChannelType" *typePtr in The new channel I/O procedures to use for \fIchannel\fR. .AP ClientData clientData in Arbitrary one-word value to pass to channel I/O procedures. diff --git a/doc/CrtChannel.3 b/doc/CrtChannel.3 index a4a6c4c..1aaf3be 100644 --- a/doc/CrtChannel.3 +++ b/doc/CrtChannel.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: CrtChannel.3,v 1.41 2008/06/29 22:28:23 dkf Exp $ +'\" RCS: @(#) $Id: CrtChannel.3,v 1.42 2008/10/04 12:33:34 nijtmans Exp $ .so man.macros .TH Tcl_CreateChannel 3 8.4 Tcl "Tcl Library Procedures" .BS @@ -22,7 +22,7 @@ Tcl_Channel ClientData \fBTcl_GetChannelInstanceData\fR(\fIchannel\fR) .sp -Tcl_ChannelType * +const Tcl_ChannelType * \fBTcl_GetChannelType\fR(\fIchannel\fR) .sp const char * @@ -312,7 +312,7 @@ details about the old structure. The \fBTcl_ChannelType\fR structure contains the following fields: .CS typedef struct Tcl_ChannelType { - char *\fItypeName\fR; + const char *\fItypeName\fR; Tcl_ChannelTypeVersion \fIversion\fR; Tcl_DriverCloseProc *\fIcloseProc\fR; Tcl_DriverInputProc *\fIinputProc\fR; @@ -875,7 +875,7 @@ the following fields: .PP .CS typedef struct Tcl_ChannelType { - char *\fItypeName\fR; + const char *\fItypeName\fR; Tcl_DriverBlockModeProc *\fIblockModeProc\fR; Tcl_DriverCloseProc *\fIcloseProc\fR; Tcl_DriverInputProc *\fIinputProc\fR; @@ -901,7 +901,7 @@ contained the following fields: .PP .CS typedef struct Tcl_ChannelType { - char *\fItypeName\fR; + const char *\fItypeName\fR; Tcl_ChannelTypeVersion \fIversion\fR; Tcl_DriverCloseProc *\fIcloseProc\fR; Tcl_DriverInputProc *\fIinputProc\fR; diff --git a/generic/tcl.decls b/generic/tcl.decls index 335d09a..b64df6d 100644 --- a/generic/tcl.decls +++ b/generic/tcl.decls @@ -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.decls,v 1.150 2008/10/04 11:51:25 nijtmans Exp $ +# RCS: @(#) $Id: tcl.decls,v 1.151 2008/10/04 12:33:34 nijtmans Exp $ library tcl @@ -327,7 +327,7 @@ declare 87 generic { Tcl_Obj *CONST objv[]) } declare 88 generic { - Tcl_Channel Tcl_CreateChannel(Tcl_ChannelType *typePtr, + Tcl_Channel Tcl_CreateChannel(CONST Tcl_ChannelType *typePtr, CONST char *chanName, ClientData instanceData, int mask) } declare 89 generic { @@ -567,7 +567,7 @@ declare 157 generic { CONST char *optionName, Tcl_DString *dsPtr) } declare 158 generic { - Tcl_ChannelType * Tcl_GetChannelType(Tcl_Channel chan) + CONST86 Tcl_ChannelType * Tcl_GetChannelType(Tcl_Channel chan) } declare 159 generic { int Tcl_GetCommandInfo(Tcl_Interp *interp, CONST char *cmdName, @@ -1011,8 +1011,9 @@ declare 280 generic { # version into the new one). declare 281 generic { - Tcl_Channel Tcl_StackChannel(Tcl_Interp *interp, Tcl_ChannelType *typePtr, - ClientData instanceData, int mask, Tcl_Channel prevChan) + Tcl_Channel Tcl_StackChannel(Tcl_Interp *interp, + CONST Tcl_ChannelType *typePtr, ClientData instanceData, + int mask, Tcl_Channel prevChan) } declare 282 generic { int Tcl_UnstackChannel(Tcl_Interp *interp, Tcl_Channel chan) diff --git a/generic/tcl.h b/generic/tcl.h index 90b9d75..26187e3 100644 --- a/generic/tcl.h +++ b/generic/tcl.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: tcl.h,v 1.273 2008/10/04 11:51:25 nijtmans Exp $ + * RCS: @(#) $Id: tcl.h,v 1.274 2008/10/04 12:33:34 nijtmans Exp $ */ #ifndef _TCL @@ -1460,7 +1460,7 @@ typedef int (Tcl_DriverTruncateProc) (ClientData instanceData, */ typedef struct Tcl_ChannelType { - char *typeName; /* The name of the channel type in Tcl + CONST char *typeName; /* The name of the channel type in Tcl * commands. This storage is owned by channel * type. */ Tcl_ChannelTypeVersion version; diff --git a/generic/tclDecls.h b/generic/tclDecls.h index bf3aa3f..2650172 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.152 2008/10/04 11:51:25 nijtmans Exp $ + * RCS: @(#) $Id: tclDecls.h,v 1.153 2008/10/04 12:33:34 nijtmans Exp $ */ #ifndef _TCLDECLS @@ -563,7 +563,7 @@ EXTERN int Tcl_CreateAliasObj (Tcl_Interp * slave, #ifndef Tcl_CreateChannel_TCL_DECLARED #define Tcl_CreateChannel_TCL_DECLARED /* 88 */ -EXTERN Tcl_Channel Tcl_CreateChannel (Tcl_ChannelType * typePtr, +EXTERN Tcl_Channel Tcl_CreateChannel (CONST Tcl_ChannelType * typePtr, CONST char * chanName, ClientData instanceData, int mask); #endif @@ -998,7 +998,7 @@ EXTERN int Tcl_GetChannelOption (Tcl_Interp * interp, #ifndef Tcl_GetChannelType_TCL_DECLARED #define Tcl_GetChannelType_TCL_DECLARED /* 158 */ -EXTERN Tcl_ChannelType * Tcl_GetChannelType (Tcl_Channel chan); +EXTERN CONST86 Tcl_ChannelType * Tcl_GetChannelType (Tcl_Channel chan); #endif #ifndef Tcl_GetCommandInfo_TCL_DECLARED #define Tcl_GetCommandInfo_TCL_DECLARED @@ -1763,7 +1763,7 @@ EXTERN void Tcl_InitMemory (Tcl_Interp * interp); #define Tcl_StackChannel_TCL_DECLARED /* 281 */ EXTERN Tcl_Channel Tcl_StackChannel (Tcl_Interp * interp, - Tcl_ChannelType * typePtr, + CONST Tcl_ChannelType * typePtr, ClientData instanceData, int mask, Tcl_Channel prevChan); #endif @@ -3772,7 +3772,7 @@ typedef struct TclStubs { int (*tcl_ConvertCountedElement) (CONST char * src, int length, char * dst, int flags); /* 85 */ int (*tcl_CreateAlias) (Tcl_Interp * slave, CONST char * slaveCmd, Tcl_Interp * target, CONST char * targetCmd, int argc, CONST84 char * CONST * argv); /* 86 */ int (*tcl_CreateAliasObj) (Tcl_Interp * slave, CONST char * slaveCmd, Tcl_Interp * target, CONST char * targetCmd, int objc, Tcl_Obj *CONST objv[]); /* 87 */ - Tcl_Channel (*tcl_CreateChannel) (Tcl_ChannelType * typePtr, CONST char * chanName, ClientData instanceData, int mask); /* 88 */ + Tcl_Channel (*tcl_CreateChannel) (CONST Tcl_ChannelType * typePtr, CONST char * chanName, ClientData instanceData, int mask); /* 88 */ void (*tcl_CreateChannelHandler) (Tcl_Channel chan, int mask, Tcl_ChannelProc * proc, ClientData clientData); /* 89 */ void (*tcl_CreateCloseHandler) (Tcl_Channel chan, Tcl_CloseProc * proc, ClientData clientData); /* 90 */ Tcl_Command (*tcl_CreateCommand) (Tcl_Interp * interp, CONST char * cmdName, Tcl_CmdProc * proc, ClientData clientData, Tcl_CmdDeleteProc * deleteProc); /* 91 */ @@ -3850,7 +3850,7 @@ typedef struct TclStubs { int (*tcl_GetChannelMode) (Tcl_Channel chan); /* 155 */ CONST84_RETURN char * (*tcl_GetChannelName) (Tcl_Channel chan); /* 156 */ int (*tcl_GetChannelOption) (Tcl_Interp * interp, Tcl_Channel chan, CONST char * optionName, Tcl_DString * dsPtr); /* 157 */ - Tcl_ChannelType * (*tcl_GetChannelType) (Tcl_Channel chan); /* 158 */ + CONST86 Tcl_ChannelType * (*tcl_GetChannelType) (Tcl_Channel chan); /* 158 */ int (*tcl_GetCommandInfo) (Tcl_Interp * interp, CONST char * cmdName, Tcl_CmdInfo * infoPtr); /* 159 */ CONST84_RETURN char * (*tcl_GetCommandName) (Tcl_Interp * interp, Tcl_Command command); /* 160 */ int (*tcl_GetErrno) (void); /* 161 */ @@ -3997,7 +3997,7 @@ typedef struct TclStubs { void (*tcl_PanicVA) (CONST char * format, va_list argList); /* 278 */ void (*tcl_GetVersion) (int * major, int * minor, int * patchLevel, int * type); /* 279 */ void (*tcl_InitMemory) (Tcl_Interp * interp); /* 280 */ - Tcl_Channel (*tcl_StackChannel) (Tcl_Interp * interp, Tcl_ChannelType * typePtr, ClientData instanceData, int mask, Tcl_Channel prevChan); /* 281 */ + Tcl_Channel (*tcl_StackChannel) (Tcl_Interp * interp, CONST Tcl_ChannelType * typePtr, ClientData instanceData, int mask, Tcl_Channel prevChan); /* 281 */ int (*tcl_UnstackChannel) (Tcl_Interp * interp, Tcl_Channel chan); /* 282 */ Tcl_Channel (*tcl_GetStackedChannel) (Tcl_Channel chan); /* 283 */ void (*tcl_SetMainLoop) (Tcl_MainLoopProc * proc); /* 284 */ diff --git a/generic/tclIO.c b/generic/tclIO.c index 08d73ec..c69a8e2 100644 --- a/generic/tclIO.c +++ b/generic/tclIO.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: tclIO.c,v 1.143 2008/05/23 21:00:44 andreas_kupries Exp $ + * RCS: @(#) $Id: tclIO.c,v 1.144 2008/10/04 12:33:34 nijtmans Exp $ */ #include "tclInt.h" @@ -208,7 +208,7 @@ static int SetChannelFromAny(Tcl_Interp *interp, Tcl_Obj *objPtr); static void UpdateStringOfChannel(Tcl_Obj *objPtr); static void FreeChannelIntRep(Tcl_Obj *objPtr); -static Tcl_ObjType tclChannelType = { +static const Tcl_ObjType tclChannelType = { "channel", /* name for this type */ FreeChannelIntRep, /* freeIntRepProc */ DupChannelIntRep, /* dupIntRepProc */ @@ -1219,7 +1219,7 @@ TclGetChannelFromObj( Tcl_Channel Tcl_CreateChannel( - Tcl_ChannelType *typePtr, /* The channel type record. */ + const Tcl_ChannelType *typePtr, /* The channel type record. */ const char *chanName, /* Name of channel to record. */ ClientData instanceData, /* Instance specific data. */ int mask) /* TCL_READABLE & TCL_WRITABLE to indicate if @@ -1415,7 +1415,7 @@ Tcl_CreateChannel( Tcl_Channel Tcl_StackChannel( Tcl_Interp *interp, /* The interpreter we are working in */ - Tcl_ChannelType *typePtr, /* The channel type record for the new + const Tcl_ChannelType *typePtr, /* The channel type record for the new * channel. */ ClientData instanceData, /* Instance specific data for the new * channel. */ @@ -1909,7 +1909,7 @@ Tcl_GetChannelThread( *---------------------------------------------------------------------- */ -Tcl_ChannelType * +const Tcl_ChannelType * Tcl_GetChannelType( Tcl_Channel chan) /* The channel to return type for. */ { diff --git a/generic/tclIO.h b/generic/tclIO.h index 23e64a0..a90817b 100644 --- a/generic/tclIO.h +++ b/generic/tclIO.h @@ -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: tclIO.h,v 1.13 2008/05/02 10:27:07 dkf Exp $ + * RCS: @(#) $Id: tclIO.h,v 1.14 2008/10/04 12:33:34 nijtmans Exp $ */ /* @@ -132,7 +132,7 @@ typedef struct Channel { struct ChannelState *state; /* Split out state information */ ClientData instanceData; /* Instance-specific data provided by creator * of channel. */ - Tcl_ChannelType *typePtr; /* Pointer to channel type structure. */ + CONST86 Tcl_ChannelType *typePtr; /* Pointer to channel type structure. */ struct Channel *downChanPtr;/* Refers to channel this one was stacked * upon. This reference is NULL for normal * channels. See Tcl_StackChannel. */ |