diff options
| -rw-r--r-- | doc/CrtObjCmd.3 | 24 | ||||
| -rw-r--r-- | doc/CrtTrace.3 | 6 | ||||
| -rw-r--r-- | doc/StringObj.3 | 2 | ||||
| -rw-r--r-- | doc/info.n | 2 | ||||
| -rw-r--r-- | generic/tcl.decls | 4 | ||||
| -rw-r--r-- | generic/tclDecls.h | 18 | ||||
| -rw-r--r-- | generic/tclProc.c | 13 | ||||
| -rw-r--r-- | generic/tclStubInit.c | 5 | ||||
| -rw-r--r-- | generic/tclTrace.c | 4 | ||||
| -rw-r--r-- | tests/http.test | 2 | ||||
| -rw-r--r-- | unix/dltest/pkga.c | 4 | ||||
| -rw-r--r-- | unix/dltest/pkgb.c | 6 | ||||
| -rw-r--r-- | unix/dltest/pkgc.c | 4 | ||||
| -rw-r--r-- | unix/dltest/pkgd.c | 4 | ||||
| -rw-r--r-- | unix/dltest/pkgooa.c | 2 | ||||
| -rw-r--r-- | unix/dltest/pkgua.c | 6 | ||||
| -rw-r--r-- | unix/dltest/pkgπ.c | 7 |
17 files changed, 57 insertions, 56 deletions
diff --git a/doc/CrtObjCmd.3 b/doc/CrtObjCmd.3 index cfe414b..641f1e9 100644 --- a/doc/CrtObjCmd.3 +++ b/doc/CrtObjCmd.3 @@ -8,7 +8,7 @@ .so man.macros .BS .SH NAME -Tcl_CreateObjCommand, Tcl_DeleteCommand, Tcl_DeleteCommandFromToken, Tcl_GetCommandInfo, Tcl_GetCommandInfoFromToken, Tcl_SetCommandInfo, Tcl_SetCommandInfoFromToken, Tcl_GetCommandName, Tcl_GetCommandFullName, Tcl_GetCommandFromObj, Tcl_RegisterCommandTypeName, Tcl_GetCommandTypeName \- implement new commands in C +Tcl_CreateObjCommand, Tcl_DeleteCommand, Tcl_DeleteCommandFromToken, Tcl_GetCommandInfo, Tcl_GetCommandInfoFromToken, Tcl_SetCommandInfo, Tcl_SetCommandInfoFromToken, Tcl_GetCommandName, Tcl_GetCommandFullName, Tcl_GetCommandFromObj \- implement new commands in C .SH SYNOPSIS .nf \fB#include <tcl.h>\fR @@ -43,13 +43,6 @@ void Tcl_Command \fBTcl_GetCommandFromObj\fR(\fIinterp, objPtr\fR) .sp -.VS "info cmdtype feature" -void -\fBTcl_RegisterCommandTypeName\fR(\fIproc, typeName\fR) -.sp -const char * -\fBTcl_GetCommandTypeName\fR(\fItoken\fR) -.VE "info cmdtype feature" .SH ARGUMENTS .AS Tcl_CmdDeleteProc *deleteProc in/out .AP Tcl_Interp *interp in @@ -308,21 +301,6 @@ specified by the name in a \fBTcl_Obj\fR. The command name is resolved relative to the current namespace. Returns NULL if the command is not found. .PP -.VS "info cmdtype feature" -\fBTcl_RegisterCommandTypeName\fR is used to associate a name (the -\fItypeName\fR argument) with a particular implementation function so that it -can then be looked up with \fBTcl_GetCommandTypeName\fR, which in turn is -called with a command token that information is wanted for and which returns -the name of the type that was registered for the implementation function used -for that command. (The lookup functionality is surfaced virtually directly in Tcl via -\fBinfo cmdtype\fR.) If there is no function registered for a particular -function, the result will be the string literal -.QW \fBnative\fR . -The registration of a name can be undone by registering a mapping to NULL -instead. The result from \fBTcl_GetCommandTypeName\fR will be exactly that -string which was registered, and not a copy; use of a compile-time constant -string is \fIstrongly recommended\fR. -.VE "info cmdtype feature" .SH "REFERENCE COUNT MANAGEMENT" .PP When the \fIproc\fR passed to \fBTcl_CreateObjCommand\fR is called, diff --git a/doc/CrtTrace.3 b/doc/CrtTrace.3 index 3c30869..e0d54c0 100644 --- a/doc/CrtTrace.3 +++ b/doc/CrtTrace.3 @@ -99,11 +99,7 @@ the Tcl interpreter will invoke the command. Any other return code is treated as if the command returned that status, and the command is \fInot\fR invoked. .PP -The \fIobjProc\fR callback must not modify \fIobjv\fR in any way. It -is, however, permissible to change the command by calling -\fBTcl_SetCommandTokenInfo\fR prior to returning. Any such change -takes effect immediately, and the command is invoked with the new -information. +The \fIobjProc\fR callback must not modify \fIobjv\fR in any way. .PP Tracing will only occur for commands at nesting level less than or equal to the \fIlevel\fR parameter (i.e. the \fIlevel\fR diff --git a/doc/StringObj.3 b/doc/StringObj.3 index 74d6d02..4991f1c 100644 --- a/doc/StringObj.3 +++ b/doc/StringObj.3 @@ -203,7 +203,7 @@ byte pointer is owned by the value manager and should not be modified by the caller. The procedure \fBTcl_GetUnicode\fR is used in the common case where the caller does not need the length of the unicode string representation. If \fIlengthPtr\fR points to an \fBint\fR variable, -and the string has more than 2^31 unicode characters, a panic will result. +and the string has more than 2^31 unicode characters, a panic will result. .PP \fBTcl_GetUniChar\fR returns the \fIindex\fR'th character in the value's Unicode representation. If the index is out of range or @@ -68,8 +68,6 @@ that represents an instance of \fBoo::object\fR or one of its subclasses. \fIcommandName\fR was created by \fBinterp create\fR. .IP \fBzlibStream\fR \fIcommandName\fR was created by \fBzlib stream\fR. -.PP -Other types may be also registered as well. See \fBTcl_RegisterCommandTypeName\fR. .RE .VE TIP426 .TP diff --git a/generic/tcl.decls b/generic/tcl.decls index 06e2b89..cc29dfd 100644 --- a/generic/tcl.decls +++ b/generic/tcl.decls @@ -2558,6 +2558,10 @@ declare 673 { int Tcl_GetUniChar(Tcl_Obj *objPtr, size_t index) } +declare 678 { + int Tcl_ProcObjCmd2(void *clientData, Tcl_Interp *interp, + size_t objc, Tcl_Obj *const objv[]) +} # ----- BASELINE -- FOR -- 8.7.0 ----- # diff --git a/generic/tclDecls.h b/generic/tclDecls.h index 398bc78..7e6b986 100644 --- a/generic/tclDecls.h +++ b/generic/tclDecls.h @@ -1807,6 +1807,13 @@ EXTERN Tcl_Obj * Tcl_GetRange(Tcl_Obj *objPtr, size_t first, size_t last); /* 673 */ EXTERN int Tcl_GetUniChar(Tcl_Obj *objPtr, size_t index); +/* Slot 674 is reserved */ +/* Slot 675 is reserved */ +/* Slot 676 is reserved */ +/* Slot 677 is reserved */ +/* 678 */ +EXTERN int Tcl_ProcObjCmd2(void *clientData, Tcl_Interp *interp, + size_t objc, Tcl_Obj *const objv[]); typedef struct { const struct TclPlatStubs *tclPlatStubs; @@ -2492,6 +2499,11 @@ typedef struct TclStubs { const char * (*tcl_UtfAtIndex) (const char *src, size_t index); /* 671 */ Tcl_Obj * (*tcl_GetRange) (Tcl_Obj *objPtr, size_t first, size_t last); /* 672 */ int (*tcl_GetUniChar) (Tcl_Obj *objPtr, size_t index); /* 673 */ + void (*reserved674)(void); + void (*reserved675)(void); + void (*reserved676)(void); + void (*reserved677)(void); + int (*tcl_ProcObjCmd2) (void *clientData, Tcl_Interp *interp, size_t objc, Tcl_Obj *const objv[]); /* 678 */ } TclStubs; extern const TclStubs *tclStubsPtr; @@ -3792,6 +3804,12 @@ extern const TclStubs *tclStubsPtr; (tclStubsPtr->tcl_GetRange) /* 672 */ #define Tcl_GetUniChar \ (tclStubsPtr->tcl_GetUniChar) /* 673 */ +/* Slot 674 is reserved */ +/* Slot 675 is reserved */ +/* Slot 676 is reserved */ +/* Slot 677 is reserved */ +#define Tcl_ProcObjCmd2 \ + (tclStubsPtr->tcl_ProcObjCmd2) /* 678 */ #endif /* defined(USE_TCL_STUBS) */ diff --git a/generic/tclProc.c b/generic/tclProc.c index 49b9967..4413b5f 100644 --- a/generic/tclProc.c +++ b/generic/tclProc.c @@ -149,6 +149,19 @@ static const Tcl_ObjType lambdaType = { */ int +Tcl_ProcObjCmd2( + TCL_UNUSED(void *), + Tcl_Interp *interp, /* Current interpreter. */ + size_t objc, /* Number of arguments. */ + Tcl_Obj *const objv[]) /* Argument objects. */ +{ + if (objc > INT_MAX) { + objc = TCL_INDEX_NONE; /* Let Tcl_ProcObjCmd generate Tcl_WrongNumArgs() */ + } + return Tcl_ProcObjCmd(NULL, interp, objc, objv); +} + +int Tcl_ProcObjCmd( TCL_UNUSED(void *), Tcl_Interp *interp, /* Current interpreter. */ diff --git a/generic/tclStubInit.c b/generic/tclStubInit.c index f41321f..fea55cb 100644 --- a/generic/tclStubInit.c +++ b/generic/tclStubInit.c @@ -1460,6 +1460,11 @@ const TclStubs tclStubs = { Tcl_UtfAtIndex, /* 671 */ Tcl_GetRange, /* 672 */ Tcl_GetUniChar, /* 673 */ + 0, /* 674 */ + 0, /* 675 */ + 0, /* 676 */ + 0, /* 677 */ + Tcl_ProcObjCmd2, /* 678 */ }; /* !END!: Do not edit above this line. */ diff --git a/generic/tclTrace.c b/generic/tclTrace.c index 2558fdc..0ef53d2 100644 --- a/generic/tclTrace.c +++ b/generic/tclTrace.c @@ -2104,10 +2104,6 @@ TraceVarProc( * 'objc' and 'objv' parameters give the parameter vector that will be * passed to the command procedure. Proc does not return a value. * - * It is permissible for 'proc' to call Tcl_SetCommandTokenInfo to change - * the command procedure or client data for the command being evaluated, - * and these changes will take effect with the current evaluation. - * * The 'level' argument specifies the maximum nesting level of calls to * be traced. If the execution depth of the interpreter exceeds 'level', * the trace callback is not executed. diff --git a/tests/http.test b/tests/http.test index aeb1029..221985f 100644 --- a/tests/http.test +++ b/tests/http.test @@ -686,7 +686,7 @@ test http-7.4 {http::formatQuery} -setup { set enc [http::config -urlencoding] } -body { # this would be reverting to http <=2.4 behavior w/o errors - # with Tcl 8.x (unknown chars become '?'), generating a + # with Tcl 8.x (unknown chars become '?'), generating a # proper exception with Tcl 9.0 http::config -urlencoding "iso8859-1" http::mapReply "∈" diff --git a/unix/dltest/pkga.c b/unix/dltest/pkga.c index 37782ea..579c323 100644 --- a/unix/dltest/pkga.c +++ b/unix/dltest/pkga.c @@ -33,7 +33,7 @@ static int Pkga_EqObjCmd( - ClientData dummy, /* Not used. */ + void *dummy, /* Not used. */ Tcl_Interp *interp, /* Current interpreter. */ int objc, /* Number of arguments. */ Tcl_Obj *const objv[]) /* Argument objects. */ @@ -78,7 +78,7 @@ Pkga_EqObjCmd( static int Pkga_QuoteObjCmd( - ClientData dummy, /* Not used. */ + void *dummy, /* Not used. */ Tcl_Interp *interp, /* Current interpreter. */ int objc, /* Number of arguments. */ Tcl_Obj *const objv[]) /* Argument strings. */ diff --git a/unix/dltest/pkgb.c b/unix/dltest/pkgb.c index d28036f..ed2c02d 100644 --- a/unix/dltest/pkgb.c +++ b/unix/dltest/pkgb.c @@ -37,7 +37,7 @@ static int Pkgb_SubObjCmd( - ClientData dummy, /* Not used. */ + void *dummy, /* Not used. */ Tcl_Interp *interp, /* Current interpreter. */ int objc, /* Number of arguments. */ Tcl_Obj *const objv[]) /* Argument objects. */ @@ -79,7 +79,7 @@ Pkgb_SubObjCmd( static int Pkgb_UnsafeObjCmd( - ClientData dummy, /* Not used. */ + void *dummy, /* Not used. */ Tcl_Interp *interp, /* Current interpreter. */ int objc, /* Number of arguments. */ Tcl_Obj *const objv[]) /* Argument objects. */ @@ -93,7 +93,7 @@ Pkgb_UnsafeObjCmd( static int Pkgb_DemoObjCmd( - ClientData dummy, /* Not used. */ + void *dummy, /* Not used. */ Tcl_Interp *interp, /* Current interpreter. */ int objc, /* Number of arguments. */ Tcl_Obj *const objv[]) /* Argument objects. */ diff --git a/unix/dltest/pkgc.c b/unix/dltest/pkgc.c index cd92cf7..8e9c829 100644 --- a/unix/dltest/pkgc.c +++ b/unix/dltest/pkgc.c @@ -33,7 +33,7 @@ static int Pkgc_SubObjCmd( - ClientData dummy, /* Not used. */ + void *dummy, /* Not used. */ Tcl_Interp *interp, /* Current interpreter. */ int objc, /* Number of arguments. */ Tcl_Obj *const objv[]) /* Argument objects. */ @@ -72,7 +72,7 @@ Pkgc_SubObjCmd( static int Pkgc_UnsafeObjCmd( - ClientData dummy, /* Not used. */ + void *dummy, /* Not used. */ Tcl_Interp *interp, /* Current interpreter. */ int objc, /* Number of arguments. */ Tcl_Obj *const objv[]) /* Argument objects. */ diff --git a/unix/dltest/pkgd.c b/unix/dltest/pkgd.c index 0c98ec4..1b97d4c 100644 --- a/unix/dltest/pkgd.c +++ b/unix/dltest/pkgd.c @@ -33,7 +33,7 @@ static int Pkgd_SubObjCmd( - ClientData dummy, /* Not used. */ + void *dummy, /* Not used. */ Tcl_Interp *interp, /* Current interpreter. */ int objc, /* Number of arguments. */ Tcl_Obj *const objv[]) /* Argument objects. */ @@ -72,7 +72,7 @@ Pkgd_SubObjCmd( static int Pkgd_UnsafeObjCmd( - ClientData dummy, /* Not used. */ + void *dummy, /* Not used. */ Tcl_Interp *interp, /* Current interpreter. */ int objc, /* Number of arguments. */ Tcl_Obj *const objv[]) /* Argument objects. */ diff --git a/unix/dltest/pkgooa.c b/unix/dltest/pkgooa.c index 5aa48a5..60ddf8b 100644 --- a/unix/dltest/pkgooa.c +++ b/unix/dltest/pkgooa.c @@ -33,7 +33,7 @@ static int Pkgooa_StubsOKObjCmd( - ClientData dummy, /* Not used. */ + void *dummy, /* Not used. */ Tcl_Interp *interp, /* Current interpreter. */ int objc, /* Number of arguments. */ Tcl_Obj *const objv[]) /* Argument objects. */ diff --git a/unix/dltest/pkgua.c b/unix/dltest/pkgua.c index 6d64352..16684a8 100644 --- a/unix/dltest/pkgua.c +++ b/unix/dltest/pkgua.c @@ -31,7 +31,7 @@ static Tcl_ThreadDataKey dataKey; #define MAX_REGISTERED_COMMANDS 2 static void -CommandDeleted(ClientData clientData) +CommandDeleted(void *clientData) { Tcl_Command *cmdToken = (Tcl_Command *)clientData; *cmdToken = NULL; @@ -120,7 +120,7 @@ PkguaDeleteTokens( static int PkguaEqObjCmd( - ClientData dummy, /* Not used. */ + void *dummy, /* Not used. */ Tcl_Interp *interp, /* Current interpreter. */ int objc, /* Number of arguments. */ Tcl_Obj *const objv[]) /* Argument objects. */ @@ -165,7 +165,7 @@ PkguaEqObjCmd( static int PkguaQuoteObjCmd( - ClientData dummy, /* Not used. */ + void *dummy, /* Not used. */ Tcl_Interp *interp, /* Current interpreter. */ int objc, /* Number of arguments. */ Tcl_Obj *const objv[]) /* Argument strings. */ diff --git a/unix/dltest/pkgπ.c b/unix/dltest/pkgπ.c index 1cf95cf..dc01fbd 100644 --- a/unix/dltest/pkgπ.c +++ b/unix/dltest/pkgπ.c @@ -14,13 +14,6 @@ #include "tcl.h" /* - * Prototypes for procedures defined later in this file: - */ - -static int Pkg\u03C0_\u03A0ObjCmd(ClientData clientData, - Tcl_Interp *interp, int objc, Tcl_Obj *const objv[]); - -/* *---------------------------------------------------------------------- * * Pkga_EqObjCmd -- |
