From bc7e98d373bca23af3b39ab27dcd19e516701091 Mon Sep 17 00:00:00 2001 From: Miguel Sofer Date: Sat, 11 Dec 2004 14:41:45 +0000 Subject: converting the static function GetNamespaceFromObj() to MODULE_SCOPE TclGetNamespaceFromObj(). --- ChangeLog | 7 +++++++ generic/tclInt.h | 6 +++++- generic/tclNamesp.c | 21 +++++++++------------ 3 files changed, 21 insertions(+), 13 deletions(-) diff --git a/ChangeLog b/ChangeLog index 168354a..84aaa0e 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +2004-12-11 Miguel Sofer + + * generic/tclInt.h: + * generic/tclNamesp.c: converting the static function + GetNamespaceFromObj() to MODULE_SCOPE TclGetNamespaceFromObj(). + 2004-12-10 Donal K. Fellows * tools/tcl.wse.in, unix/tcl.spec, win/README.binary, README: @@ -6,6 +12,7 @@ development from the recent 8.5a2 release. 2004-12-10 Miguel Sofer + * generic/tclCompile.c (TclInitCompiledLocals): * generic/tclCompile.h: * generic/tclInt.h: diff --git a/generic/tclInt.h b/generic/tclInt.h index 11ddcf3..983cceb 100644 --- a/generic/tclInt.h +++ b/generic/tclInt.h @@ -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: tclInt.h,v 1.205 2004/12/10 13:09:14 msofer Exp $ + * RCS: @(#) $Id: tclInt.h,v 1.206 2004/12/11 14:41:46 msofer Exp $ */ #ifndef _TCLINT @@ -1835,6 +1835,10 @@ MODULE_SCOPE void TclFinalizeSynchronization _ANSI_ARGS_((void)); MODULE_SCOPE void TclFinalizeLock _ANSI_ARGS_((void)); MODULE_SCOPE void TclFinalizeThreadData _ANSI_ARGS_((void)); MODULE_SCOPE Tcl_Obj * TclGetBgErrorHandler _ANSI_ARGS_((Tcl_Interp *interp)); +MODULE_SCOPE int TclGetNamespaceFromObj _ANSI_ARGS_(( + Tcl_Interp *interp, Tcl_Obj *objPtr, + Tcl_Namespace **nsPtrPtr)); + MODULE_SCOPE Tcl_Obj * TclGetProcessGlobalValue _ANSI_ARGS_ (( ProcessGlobalValue *pgvPtr)); MODULE_SCOPE int TclGlob _ANSI_ARGS_((Tcl_Interp *interp, diff --git a/generic/tclNamesp.c b/generic/tclNamesp.c index 778b243..b9818a1 100644 --- a/generic/tclNamesp.c +++ b/generic/tclNamesp.c @@ -21,7 +21,7 @@ * See the file "license.terms" for information on usage and redistribution * of this file, and for a DISCLAIMER OF ALL WARRANTIES. * - * RCS: @(#) $Id: tclNamesp.c,v 1.68 2004/12/10 00:16:55 dkf Exp $ + * RCS: @(#) $Id: tclNamesp.c,v 1.69 2004/12/11 14:41:47 msofer Exp $ */ #include "tclInt.h" @@ -196,9 +196,6 @@ static char * EstablishErrorInfoTraces _ANSI_ARGS_(( ClientData clientData, Tcl_Interp *interp, CONST char *name1, CONST char *name2, int flags)); static void FreeNsNameInternalRep _ANSI_ARGS_((Tcl_Obj *objPtr)); -static int GetNamespaceFromObj _ANSI_ARGS_(( - Tcl_Interp *interp, Tcl_Obj *objPtr, - Tcl_Namespace **nsPtrPtr)); static int InvokeImportedCmd _ANSI_ARGS_(( ClientData clientData, Tcl_Interp *interp, int objc, Tcl_Obj *CONST objv[])); @@ -2592,7 +2589,7 @@ TclResetShadowedCmdRefs(interp, newCmdPtr) /* *---------------------------------------------------------------------- * - * GetNamespaceFromObj -- + * TclGetNamespaceFromObj -- * * Gets the namespace specified by the name in a Tcl_Obj. * @@ -2614,8 +2611,8 @@ TclResetShadowedCmdRefs(interp, newCmdPtr) *---------------------------------------------------------------------- */ -static int -GetNamespaceFromObj(interp, objPtr, nsPtrPtr) +int +TclGetNamespaceFromObj(interp, objPtr, nsPtrPtr) Tcl_Interp *interp; /* The current interpreter. */ Tcl_Obj *objPtr; /* The object to be resolved as the name * of a namespace. */ @@ -2868,7 +2865,7 @@ NamespaceChildrenCmd(dummy, interp, objc, objv) if (objc == 2) { nsPtr = (Namespace *) Tcl_GetCurrentNamespace(interp); } else if ((objc == 3) || (objc == 4)) { - if (GetNamespaceFromObj(interp, objv[2], &namespacePtr) != TCL_OK) { + if (TclGetNamespaceFromObj(interp, objv[2], &namespacePtr) != TCL_OK) { return TCL_ERROR; } if (namespacePtr == NULL) { @@ -3200,7 +3197,7 @@ NamespaceEvalCmd(dummy, interp, objc, objv) * namespace object along the way. */ - result = GetNamespaceFromObj(interp, objv[2], &namespacePtr); + result = TclGetNamespaceFromObj(interp, objv[2], &namespacePtr); if (result != TCL_OK) { return result; } @@ -3306,7 +3303,7 @@ NamespaceExistsCmd(dummy, interp, objc, objv) * Check whether the given namespace exists */ - if (GetNamespaceFromObj(interp, objv[2], &namespacePtr) != TCL_OK) { + if (TclGetNamespaceFromObj(interp, objv[2], &namespacePtr) != TCL_OK) { return TCL_ERROR; } @@ -3611,7 +3608,7 @@ NamespaceInscopeCmd(dummy, interp, objc, objv) * Resolve the namespace reference. */ - result = GetNamespaceFromObj(interp, objv[2], &namespacePtr); + result = TclGetNamespaceFromObj(interp, objv[2], &namespacePtr); if (result != TCL_OK) { return result; } @@ -3783,7 +3780,7 @@ NamespaceParentCmd(dummy, interp, objc, objv) if (objc == 2) { nsPtr = Tcl_GetCurrentNamespace(interp); } else if (objc == 3) { - result = GetNamespaceFromObj(interp, objv[2], &nsPtr); + result = TclGetNamespaceFromObj(interp, objv[2], &nsPtr); if (result != TCL_OK) { return result; } -- cgit v0.12