summaryrefslogtreecommitdiffstats
path: root/generic/tclIntDecls.h
diff options
context:
space:
mode:
authorMiguel Sofer <miguel.sofer@gmail.com>2002-07-15 22:18:02 (GMT)
committerMiguel Sofer <miguel.sofer@gmail.com>2002-07-15 22:18:02 (GMT)
commit238c1dc36a4a340625f96ed76c46bd93872562ac (patch)
tree716557af52e29f2dec87f80a04f9b29ab62cded9 /generic/tclIntDecls.h
parent1d0aa1a4beb25c12aa52099b1de6c4227578333a (diff)
downloadtcl-238c1dc36a4a340625f96ed76c46bd93872562ac.zip
tcl-238c1dc36a4a340625f96ed76c46bd93872562ac.tar.gz
tcl-238c1dc36a4a340625f96ed76c46bd93872562ac.tar.bz2
* generic/tclVar.c: refactorisation to reuse already looked-up Var
pointers; definition of three new Tcl_Obj types to cache variable name parsing and lookup for later reuse; modification of internal functions to profit from the caching. * generic/tclInt.decls: * generic/tclInt.h: * generic/tclIntDecls.h: * generic/tclNamesp.c: adding CONST qualifiers to variable names passed to Tcl_FindNamespaceVar and to variable resolvers; adding CONST qualifier to the 'msg' argument to TclLookupVar. Needed to avoid code duplication in the new tclVar.c code. * tests/set-old.test: * tests/var.test: slight modification of error messages due to the modifications in the tclVar.c code.
Diffstat (limited to 'generic/tclIntDecls.h')
-rw-r--r--generic/tclIntDecls.h12
1 files changed, 6 insertions, 6 deletions
diff --git a/generic/tclIntDecls.h b/generic/tclIntDecls.h
index a03d113..9fbd8ac 100644
--- a/generic/tclIntDecls.h
+++ b/generic/tclIntDecls.h
@@ -11,7 +11,7 @@
* See the file "license.terms" for information on usage and redistribution
* of this file, and for a DISCLAIMER OF ALL WARRANTIES.
*
- * RCS: @(#) $Id: tclIntDecls.h,v 1.42 2002/06/17 22:52:51 hobbs Exp $
+ * RCS: @(#) $Id: tclIntDecls.h,v 1.43 2002/07/15 22:18:06 msofer Exp $
*/
#ifndef _TCLINTDECLS
@@ -210,8 +210,8 @@ EXTERN Proc * TclIsProc _ANSI_ARGS_((Command * cmdPtr));
/* 58 */
EXTERN Var * TclLookupVar _ANSI_ARGS_((Tcl_Interp * interp,
char * part1, CONST char * part2, int flags,
- char * msg, int createPart1, int createPart2,
- Var ** arrayPtrPtr));
+ CONST char * msg, int createPart1,
+ int createPart2, Var ** arrayPtrPtr));
/* Slot 59 is reserved */
/* 60 */
EXTERN int TclNeedSpace _ANSI_ARGS_((CONST char * start,
@@ -373,7 +373,7 @@ EXTERN int Tcl_GetNamespaceResolvers _ANSI_ARGS_((
Tcl_ResolverInfo * resInfo));
/* 120 */
EXTERN Tcl_Var Tcl_FindNamespaceVar _ANSI_ARGS_((
- Tcl_Interp * interp, char * name,
+ Tcl_Interp * interp, CONST char * name,
Tcl_Namespace * contextNsPtr, int flags));
/* 121 */
EXTERN int Tcl_ForgetImport _ANSI_ARGS_((Tcl_Interp * interp,
@@ -597,7 +597,7 @@ typedef struct TclIntStubs {
Proc * (*tclIsProc) _ANSI_ARGS_((Command * cmdPtr)); /* 55 */
void *reserved56;
void *reserved57;
- Var * (*tclLookupVar) _ANSI_ARGS_((Tcl_Interp * interp, char * part1, CONST char * part2, int flags, char * msg, int createPart1, int createPart2, Var ** arrayPtrPtr)); /* 58 */
+ Var * (*tclLookupVar) _ANSI_ARGS_((Tcl_Interp * interp, char * part1, CONST char * part2, int flags, CONST char * msg, int createPart1, int createPart2, Var ** arrayPtrPtr)); /* 58 */
void *reserved59;
int (*tclNeedSpace) _ANSI_ARGS_((CONST char * start, CONST char * end)); /* 60 */
Tcl_Obj * (*tclNewProcBodyObj) _ANSI_ARGS_((Proc * procPtr)); /* 61 */
@@ -675,7 +675,7 @@ typedef struct TclIntStubs {
Tcl_Namespace * (*tcl_FindNamespace) _ANSI_ARGS_((Tcl_Interp * interp, CONST char * name, Tcl_Namespace * contextNsPtr, int flags)); /* 117 */
int (*tcl_GetInterpResolvers) _ANSI_ARGS_((Tcl_Interp * interp, CONST char * name, Tcl_ResolverInfo * resInfo)); /* 118 */
int (*tcl_GetNamespaceResolvers) _ANSI_ARGS_((Tcl_Namespace * namespacePtr, Tcl_ResolverInfo * resInfo)); /* 119 */
- Tcl_Var (*tcl_FindNamespaceVar) _ANSI_ARGS_((Tcl_Interp * interp, char * name, Tcl_Namespace * contextNsPtr, int flags)); /* 120 */
+ Tcl_Var (*tcl_FindNamespaceVar) _ANSI_ARGS_((Tcl_Interp * interp, CONST char * name, Tcl_Namespace * contextNsPtr, int flags)); /* 120 */
int (*tcl_ForgetImport) _ANSI_ARGS_((Tcl_Interp * interp, Tcl_Namespace * nsPtr, CONST char * pattern)); /* 121 */
Tcl_Command (*tcl_GetCommandFromObj) _ANSI_ARGS_((Tcl_Interp * interp, Tcl_Obj * objPtr)); /* 122 */
void (*tcl_GetCommandFullName) _ANSI_ARGS_((Tcl_Interp * interp, Tcl_Command command, Tcl_Obj * objPtr)); /* 123 */