From 96ba124114a77f7be6cfb173ee9084c01f789512 Mon Sep 17 00:00:00 2001 From: "jan.nijtmans" Date: Thu, 4 Apr 2024 13:06:32 +0000 Subject: Backout [0a9ae478ac], as requested --- doc/FileSystem.3 | 8 ++++---- doc/source.n | 2 +- generic/tcl.decls | 2 +- generic/tclCmdMZ.c | 6 +++--- generic/tclDecls.h | 4 ++-- generic/tclEncoding.c | 8 ++++---- generic/tclIOUtil.c | 12 ++++++------ generic/tclInt.decls | 4 ++-- generic/tclInt.h | 2 +- generic/tclIntDecls.h | 8 ++++---- generic/tclMain.c | 8 ++++---- 11 files changed, 32 insertions(+), 32 deletions(-) diff --git a/doc/FileSystem.3 b/doc/FileSystem.3 index 2db2485..7ac93c8 100644 --- a/doc/FileSystem.3 +++ b/doc/FileSystem.3 @@ -54,7 +54,7 @@ Tcl_Obj * \fBTcl_FSListVolumes\fR(\fIvoid\fR) .sp int -\fBTcl_FSEvalFileEx\fR(\fIinterp, pathPtr, encoding\fR) +\fBTcl_FSEvalFileEx\fR(\fIinterp, pathPtr, encodingName\fR) .sp int \fBTcl_FSEvalFile\fR(\fIinterp, pathPtr\fR) @@ -201,7 +201,7 @@ rename operation. .AP Tcl_Obj *destPathPtr in As for \fIpathPtr\fR, but used for the destination filename for a copy or rename operation. -.AP "const char" *encoding in +.AP "const char" *encodingName in The encoding of the data stored in the file identified by \fIpathPtr\fR and to be evaluated. .AP "const char" *pattern in @@ -415,10 +415,10 @@ accumulates the return values in a list which is returned to the caller (with a reference count of 0). .PP \fBTcl_FSEvalFileEx\fR reads the file given by \fIpathPtr\fR using -the encoding identified by \fIencoding\fR and evaluates +the encoding identified by \fIencodingName\fR and evaluates its contents as a Tcl script. It returns the same information as \fBTcl_EvalObjEx\fR. -If \fIencoding\fR is NULL, the system encoding is used for +If \fIencodingName\fR is NULL, the system encoding is used for reading the file contents. If the file could not be read then a Tcl error is returned to describe why the file could not be read. diff --git a/doc/source.n b/doc/source.n index d306765..82fefa6 100644 --- a/doc/source.n +++ b/doc/source.n @@ -15,7 +15,7 @@ source \- Evaluate a file or resource as a Tcl script .SH SYNOPSIS \fBsource \fIfileName\fR .sp -\fBsource\fR \fB\-encoding \fIencoding fileName\fR +\fBsource\fR \fB\-encoding \fIencodingName fileName\fR .BE .SH DESCRIPTION .PP diff --git a/generic/tcl.decls b/generic/tcl.decls index 72c30be..2f21fa5 100644 --- a/generic/tcl.decls +++ b/generic/tcl.decls @@ -1867,7 +1867,7 @@ declare 517 { # TIP#137 (encoding-aware source command) dgp for Anton Kovalenko declare 518 { int Tcl_FSEvalFileEx(Tcl_Interp *interp, Tcl_Obj *fileName, - const char *encoding) + const char *encodingName) } # TIP#121 (exit handler) dkf for Joe Mistachkin diff --git a/generic/tclCmdMZ.c b/generic/tclCmdMZ.c index 2c0c27b..41782b0 100644 --- a/generic/tclCmdMZ.c +++ b/generic/tclCmdMZ.c @@ -988,7 +988,7 @@ TclNRSourceObjCmd( int objc, /* Number of arguments. */ Tcl_Obj *const objv[]) /* Argument objects. */ { - const char *encoding = NULL; + const char *encodingName = NULL; Tcl_Obj *fileName; if (objc != 2 && objc !=4) { @@ -1008,10 +1008,10 @@ TclNRSourceObjCmd( "option", TCL_EXACT, &index)) { return TCL_ERROR; } - encoding = TclGetString(objv[2]); + encodingName = TclGetString(objv[2]); } - return TclNREvalFile(interp, fileName, encoding); + return TclNREvalFile(interp, fileName, encodingName); } /* diff --git a/generic/tclDecls.h b/generic/tclDecls.h index 801dcc7..a91f718 100644 --- a/generic/tclDecls.h +++ b/generic/tclDecls.h @@ -1497,7 +1497,7 @@ EXTERN void Tcl_GetCommandFullName(Tcl_Interp *interp, Tcl_Command command, Tcl_Obj *objPtr); /* 518 */ EXTERN int Tcl_FSEvalFileEx(Tcl_Interp *interp, - Tcl_Obj *fileName, const char *encoding); + Tcl_Obj *fileName, const char *encodingName); /* 519 */ EXTERN Tcl_ExitProc * Tcl_SetExitProc(TCL_NORETURN1 Tcl_ExitProc *proc); /* 520 */ @@ -2427,7 +2427,7 @@ typedef struct TclStubs { Tcl_Command (*tcl_FindCommand) (Tcl_Interp *interp, const char *name, Tcl_Namespace *contextNsPtr, int flags); /* 515 */ Tcl_Command (*tcl_GetCommandFromObj) (Tcl_Interp *interp, Tcl_Obj *objPtr); /* 516 */ void (*tcl_GetCommandFullName) (Tcl_Interp *interp, Tcl_Command command, Tcl_Obj *objPtr); /* 517 */ - int (*tcl_FSEvalFileEx) (Tcl_Interp *interp, Tcl_Obj *fileName, const char *encoding); /* 518 */ + int (*tcl_FSEvalFileEx) (Tcl_Interp *interp, Tcl_Obj *fileName, const char *encodingName); /* 518 */ Tcl_ExitProc * (*tcl_SetExitProc) (TCL_NORETURN1 Tcl_ExitProc *proc); /* 519 */ void (*tcl_LimitAddHandler) (Tcl_Interp *interp, int type, Tcl_LimitHandlerProc *handlerProc, ClientData clientData, Tcl_LimitHandlerDeleteProc *deleteProc); /* 520 */ void (*tcl_LimitRemoveHandler) (Tcl_Interp *interp, int type, Tcl_LimitHandlerProc *handlerProc, ClientData clientData); /* 521 */ diff --git a/generic/tclEncoding.c b/generic/tclEncoding.c index 3e9bd24..ba9f811 100644 --- a/generic/tclEncoding.c +++ b/generic/tclEncoding.c @@ -496,13 +496,13 @@ FillEncodingFileMap(void) TclListObjGetElements(NULL, matchFileList, &numFiles, &filev); for (j=0; j