Skip to content

Commit

Permalink
Deprecate Tcl_CreateCommand() too. Use Tcl_CreateObjCommand2() in all…
Browse files Browse the repository at this point in the history
… testcases
  • Loading branch information
jan.nijtmans committed Nov 10, 2024
1 parent 060ce9e commit e3d9add
Show file tree
Hide file tree
Showing 5 changed files with 67 additions and 105 deletions.
2 changes: 2 additions & 0 deletions generic/tclBasic.c
Original file line number Diff line number Diff line change
Expand Up @@ -2515,6 +2515,7 @@ Tcl_ExposeCommand(
*----------------------------------------------------------------------
*/

#ifndef TCL_NO_DEPRECATED
Tcl_Command
Tcl_CreateCommand(
Tcl_Interp *interp, /* Token for command interpreter returned by a
Expand Down Expand Up @@ -2686,6 +2687,7 @@ Tcl_CreateCommand(
TclResetShadowedCmdRefs(interp, cmdPtr);
return (Tcl_Command) cmdPtr;
}
#endif /* TCL_NO_DEPRECATED */

/*
*----------------------------------------------------------------------
Expand Down
1 change: 1 addition & 0 deletions generic/tclDecls.h
Original file line number Diff line number Diff line change
Expand Up @@ -4150,6 +4150,7 @@ extern const TclStubs *tclStubsPtr;
#undef TclUtfNext
#undef TclUtfPrev
#ifdef TCL_NO_DEPRECATED
# undef Tcl_CreateCommand
# undef Tcl_CreateObjCommand
# undef Tcl_CreateTrace
# undef Tcl_CreateObjTrace
Expand Down
1 change: 1 addition & 0 deletions generic/tclStubInit.c
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,7 @@
#define TclUnusedStubEntry 0

#ifdef TCL_NO_DEPRECATED
# define Tcl_CreateCommand 0
# define Tcl_CreateObjCommand 0
# define Tcl_CreateTrace 0
# define Tcl_CreateObjTrace 0
Expand Down
Loading

0 comments on commit e3d9add

Please sign in to comment.