diff options
Diffstat (limited to 'generic')
-rw-r--r-- | generic/tclBasic.c | 9 | ||||
-rw-r--r-- | generic/tclCompCmds.c | 4 | ||||
-rw-r--r-- | generic/tclCompile.c | 8 | ||||
-rw-r--r-- | generic/tclCompile.h | 4 | ||||
-rw-r--r-- | generic/tclIOUtil.c | 14 | ||||
-rw-r--r-- | generic/tclInt.h | 5 | ||||
-rw-r--r-- | generic/tclParse.c | 10 | ||||
-rw-r--r-- | generic/tclProc.c | 4 |
8 files changed, 28 insertions, 30 deletions
diff --git a/generic/tclBasic.c b/generic/tclBasic.c index 719203d..e8fa7ad 100644 --- a/generic/tclBasic.c +++ b/generic/tclBasic.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: tclBasic.c,v 1.1.2.2 1998/09/24 23:58:40 stanton Exp $ + * RCS: @(#) $Id: tclBasic.c,v 1.1.2.3 1998/09/30 20:46:21 stanton Exp $ */ #include "tclInt.h" @@ -903,7 +903,6 @@ DeleteInterpProc(interp) Tcl_HashEntry *hPtr; Tcl_HashSearch search; Tcl_HashTable *hTablePtr; - AssocData *dPtr; ResolverScheme *resPtr, *nextResPtr; int i; @@ -2629,12 +2628,12 @@ Tcl_EvalObj(interp, objPtr, flags) if (objPtr->typePtr == &tclByteCodeType) { codePtr = (ByteCode *) objPtr->internalRep.otherValuePtr; - if ((codePtr->iPtr != iPtr) + if (((Interp *) *codePtr->interpHandle != iPtr) || (codePtr->compileEpoch != iPtr->compileEpoch) || (codePtr->nsPtr != namespacePtr) || (codePtr->nsEpoch != namespacePtr->resolverEpoch)) { if (codePtr->flags & TCL_BYTECODE_PRECOMPILED) { - if (codePtr->iPtr != iPtr) { + if ((Interp *) *codePtr->interpHandle != iPtr) { panic("Tcl_EvalObj: compiled script jumped interps"); } codePtr->compileEpoch = iPtr->compileEpoch; @@ -3638,7 +3637,7 @@ Tcl_ExprObj(interp, objPtr, resultPtrPtr) if (((Interp *) *codePtr->interpHandle != iPtr) || (codePtr->compileEpoch != iPtr->compileEpoch)) { if (codePtr->flags & TCL_BYTECODE_PRECOMPILED) { - if (codePtr->iPtr != iPtr) { + if ((Interp *) *codePtr->interpHandle != iPtr) { panic("Tcl_ExprObj: compiled expression jumped interps"); } codePtr->compileEpoch = iPtr->compileEpoch; diff --git a/generic/tclCompCmds.c b/generic/tclCompCmds.c index 824818a..6797c96 100644 --- a/generic/tclCompCmds.c +++ b/generic/tclCompCmds.c @@ -114,9 +114,9 @@ TclCompileCatchCmd(interp, parsePtr, envPtr) { JumpFixup jumpFixup; Tcl_Token *cmdTokenPtr, *nameTokenPtr; - char *name, *p; + char *name; int localIndex, nameChars, range, maxDepth, startOffset, jumpDist; - int i, code; + int code; char buffer[32 + TCL_INTEGER_SPACE]; envPtr->maxStackDepth = 0; diff --git a/generic/tclCompile.c b/generic/tclCompile.c index f29b1c4..7288f86 100644 --- a/generic/tclCompile.c +++ b/generic/tclCompile.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: tclCompile.c,v 1.1.2.2 1998/09/24 23:58:44 stanton Exp $ + * RCS: @(#) $Id: tclCompile.c,v 1.1.2.3 1998/09/30 20:46:23 stanton Exp $ */ #include "tclInt.h" @@ -2180,7 +2180,7 @@ TclCreateExceptRange(type, envPtr) */ int -TclCreateAuxData(clientData, dupProc, freeProc, envPtr) +TclCreateAuxData(clientData, typePtr, envPtr) ClientData clientData; /* The compilation auxiliary data to store * in the new aux data record. */ AuxDataType *typePtr; /* Pointer to the type to attach to this AuxData */ @@ -2577,7 +2577,7 @@ TclRegisterAuxDataType(typePtr) * If there's already a type with the given name, remove it. */ - hPtr = Tcl_FindHashEntry(&tsdPtr->auxDataTypeTable, typePtr->name); + hPtr = Tcl_FindHashEntry(&auxDataTypeTable, typePtr->name); if (hPtr != (Tcl_HashEntry *) NULL) { Tcl_DeleteHashEntry(hPtr); } @@ -2586,7 +2586,7 @@ TclRegisterAuxDataType(typePtr) * Now insert the new object type. */ - hPtr = Tcl_CreateHashEntry(&tsdPtr->auxDataTypeTable, typePtr->name, &new); + hPtr = Tcl_CreateHashEntry(&auxDataTypeTable, typePtr->name, &new); if (new) { Tcl_SetHashValue(hPtr, typePtr); } diff --git a/generic/tclCompile.h b/generic/tclCompile.h index 0b1b3ec..b7da7c4 100644 --- a/generic/tclCompile.h +++ b/generic/tclCompile.h @@ -6,7 +6,7 @@ * See the file "license.terms" for information on usage and redistribution * of this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclCompile.h,v 1.1.2.2 1998/09/24 23:58:46 stanton Exp $ + * RCS: @(#) $Id: tclCompile.h,v 1.1.2.3 1998/09/30 20:46:24 stanton Exp $ */ #ifndef _TCLCOMPILATION @@ -670,6 +670,8 @@ typedef struct ForeachInfo { * THE LAST FIELD IN THE STRUCTURE! */ } ForeachInfo; +extern AuxDataType tclForeachInfoType; + /* * Structure containing a cached pointer to a command that is the result * of resolving the command's name in some namespace. It is the internal diff --git a/generic/tclIOUtil.c b/generic/tclIOUtil.c index c80cb9b..133f41b 100644 --- a/generic/tclIOUtil.c +++ b/generic/tclIOUtil.c @@ -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: tclIOUtil.c,v 1.1.2.3 1998/09/28 20:24:18 stanton Exp $ + * RCS: @(#) $Id: tclIOUtil.c,v 1.1.2.4 1998/09/30 20:46:25 stanton Exp $ */ #include "tclInt.h" @@ -277,6 +277,7 @@ Tcl_EvalFile(interp, fileName) * will be performed on this name. */ { int result, length; + struct stat statBuf; char *oldScriptFile; Interp *iPtr; Tcl_DString nameString; @@ -292,18 +293,13 @@ Tcl_EvalFile(interp, fileName) result = TCL_ERROR; objPtr = Tcl_NewObj(); - if (nativeName != Tcl_DStringValue(&buffer)) { - Tcl_DStringSetLength(&buffer, 0); - Tcl_DStringAppend(&buffer, nativeName, -1); - nativeName = Tcl_DStringValue(&buffer); - } - if (TclStat(nativeName, &statBuf) == -1) { + if (TclStat(name, &statBuf) == -1) { Tcl_SetErrno(errno); Tcl_AppendResult(interp, "couldn't read file \"", fileName, "\": ", Tcl_PosixError(interp), (char *) NULL); - goto error; + goto end; } - chan = Tcl_OpenFileChannel(interp, nativeName, "r", 0644); + chan = Tcl_OpenFileChannel(interp, name, "r", 0644); if (chan == (Tcl_Channel) NULL) { Tcl_ResetResult(interp); Tcl_AppendResult(interp, "couldn't read file \"", fileName, diff --git a/generic/tclInt.h b/generic/tclInt.h index f975005..472a922 100644 --- a/generic/tclInt.h +++ b/generic/tclInt.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: tclInt.h,v 1.1.2.2 1998/09/24 23:58:53 stanton Exp $ + * RCS: @(#) $Id: tclInt.h,v 1.1.2.3 1998/09/30 20:46:25 stanton Exp $ */ #ifndef _TCLINT @@ -1936,6 +1936,8 @@ EXTERN int TclInvokeObjectCommand _ANSI_ARGS_(( EXTERN int TclInvokeStringCommand _ANSI_ARGS_(( ClientData clientData, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])); +EXTERN int TclIsLocalScalar _ANSI_ARGS_((CONST char *src, + int len)); EXTERN Proc * TclIsProc _ANSI_ARGS_((Command *cmdPtr)); EXTERN int TclLooksLikeInt _ANSI_ARGS_((char *bytes, int length)); @@ -1982,7 +1984,6 @@ EXTERN int TclpCreateProcess _ANSI_ARGS_((Tcl_Interp *interp, EXTERN TclFile TclpCreateTempFile _ANSI_ARGS_((CONST char *contents)); EXTERN int TclpDeleteFile _ANSI_ARGS_((CONST char *path)); EXTERN void TclpExit _ANSI_ARGS_((int status)); -EXTERN void TclpFinalize _ANSI_ARGS_((void)); EXTERN void TclpFinalizeCondition _ANSI_ARGS_(( Tcl_Condition *condPtr)); EXTERN void TclpFinalizeMutex _ANSI_ARGS_((Tcl_Mutex *mutexPtr)); diff --git a/generic/tclParse.c b/generic/tclParse.c index 36ace07..8fd981a 100644 --- a/generic/tclParse.c +++ b/generic/tclParse.c @@ -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: tclParse.c,v 1.1.2.2 1998/09/24 23:59:00 stanton Exp $ + * RCS: @(#) $Id: tclParse.c,v 1.1.2.3 1998/09/30 20:46:26 stanton Exp $ */ #include "tclInt.h" @@ -2055,12 +2055,12 @@ TclIsLocalScalar(src, len) CONST char *src; int len; { - char *p; - char *lastChar = src + (len - 1); + CONST char *p; + CONST char *lastChar = src + (len - 1); for (p = src; p <= lastChar; p++) { - if ((CHAR_TYPE(p, lastChar) != TCL_NORMAL) && - (CHAR_TYPE(p, lastChar) != TCL_COMMAND_END)) { + if ((CHAR_TYPE(*p) != TYPE_NORMAL) && + (CHAR_TYPE(*p) != TYPE_COMMAND_END)) { /* * TCL_COMMAND_END is returned for the last character * of the string. By this point we know it isn't diff --git a/generic/tclProc.c b/generic/tclProc.c index 385ad93..ce0323e 100644 --- a/generic/tclProc.c +++ b/generic/tclProc.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: tclProc.c,v 1.1.2.2 1998/09/24 23:59:02 stanton Exp $ + * RCS: @(#) $Id: tclProc.c,v 1.1.2.3 1998/09/30 20:46:26 stanton Exp $ */ #include "tclInt.h" @@ -49,7 +49,7 @@ Tcl_ProcObjCmd(dummy, interp, objc, objv) Tcl_Obj *CONST objv[]; /* Argument objects. */ { register Interp *iPtr = (Interp *) interp; - register Proc *procPtr; + Proc *procPtr; char *fullName, *procName; Namespace *nsPtr, *altNsPtr, *cxtNsPtr; Tcl_Command cmd; |