summaryrefslogtreecommitdiffstats
path: root/generic/tclNamesp.c
Commit message (Collapse)AuthorAgeFilesLines
* Make a comment look nicer. :-)dkf2006-10-281-3/+3
|
* Allow extensions that use the internal stubs to set a namespace path.dkf2006-10-271-8/+5
|
* * generic/tclInterp.c (ApplyObjCmd):aMiguel Sofer2006-10-261-3/+3
| | | | | * generic/tclNamesp.c (EnsembleImplementationCmd): replaced ckalloc (heap) with TclStackAlloc (execution stack).
* * library/clock.tcl (format, scan): corrected wrong # argsMiguel Sofer2006-10-231-10/+14
| | | | | | | | | | | | | | | | | * tests/clock.test (3.1, 34.1): messages to make use of the new rewrite capabilities of [info level] * generic/tcl.h: Lets TEOV update the iPtr->objc/objv * generic/tclBasic.c: fields, except when the (new) flag bit * generic/tclInt.h: TCL_EVAL_NOREWRITE is present. This * generic/tclNamesp.c: causes [info level] to know and use * generic/tclProc.c: ensemble rewrites [Bug 1577492] * tests/namespace.test: ***POTENTIAL INCOMPATIBILITY*** The return value from [info level 0] on interp alias calls is changed: previously returned the target command (including curried values), now returns the source - what was actually called.
* * generic/tcl.h: Modified the Tcl call stack soMiguel Sofer2006-10-231-20/+18
| | | | | | | | | | | | | * generic/tclBasic.c: there is always a valid CallFrame, even * generic/tclCmdIL.c: at level 0 [Patch 1577278]. Most of the * generic/tclInt.h: changes involve removing tests for * generic/tclNamesp.c: iPtr->(var)framePtr==NULL. There is now a * generic/tclObj.c: CallFrame pushed at interp creation * generic/tclProc.c: with a pointer to it stored in * generic/tclTrace.c: iPtr->rootFramePtr. A second unused * generic/tclVar.c: field in Interp is hijacked to enable further functionality, currently unused (but with several FRQs depending on it).
* Undo mistaken commit to wrong branch caused by CVS fumble... :-}dkf2006-10-201-7/+9
|
* Consolidated TIP#257 patch applied to HEAD to allow for experimentation bydkf2006-10-201-9/+7
| | | | other developers
* * generic/tclNamespace.c (TclTeardownNamespace): After thedgp2006-10-101-1/+2
| | | | | | commandPathSourceList of a namespace is cleared, set the commandPathSourceList to NULL so we don't try to walk the list a second time, possibly after it is freed. [Bug 1566526]
* undo last commit.dgp2006-08-281-2/+2
|
* Fixes for [Bug 1547662] and [Bug 1547681]Joe Mistachkin2006-08-281-2/+2
|
* bugfix, docs clarification and new tests for 'namespace upvar' [Bug 1546833]Miguel Sofer2006-08-261-2/+14
|
* It seems that the original submitter of the patch didn't test it. Add a dkf2006-08-111-1/+9
| | | | critical buffer reset so that nested namespaces get the right fullName...
* Applied [Patch 1352382]dkf2006-08-111-150/+150
|
* silence a strict aliasing warning from gccrmax2006-03-131-3/+4
|
* Space/style improvementsdkf2006-02-021-107/+139
|
* TIP#181 IMPLEMENTATIONdgp2006-02-011-3/+182
| | | | | | | | | | | | | * doc/Namespace.3: New command [namespace unknown]. New public * doc/namespace.n: C routines Tcl_(Get|Set)NamespaceUnknownHandler. * doc/unknown.n: [Patch 958222]. * generic/tcl.decls: * generic/tclBasic.c: * generic/tclInt.h: * generic/tclNamesp.c: * tests/namespace.test: * generic/tclDecls.h: make genstubs * generic/tclStubInit.c:
* TIP#250 IMPLEMENTATIONdgp2006-02-011-3/+83
| | | | | | | | | * doc/namespace.n: New command [namespace upvar]. [Patch 1275435] * generic/tclInt.h: * generic/tclNamesp.c: * generic/tclVar.c: * tests/namespace.test: * tests/upvar.test:
* * generic/tclBasic.c: Moved Tcl_LogCommandInfo from tclBasic.c todgp2006-01-111-1/+82
| | | | | | | | | | * generic/tclNamesp.c: tclNamesp.c to get access to identifier with * tests/error.test (error-7.0): file scope. Added check for traces on ::errorInfo, and when present fall back to contruction of the stack trace in the variable so that write trace notification timings are compatible with earlier Tcl releases. This reduces, but does not completely eliminate the ***POTENTIAL INCOMPATIBILITY*** created by the 2004-10-15 commit. [Bug 1397843].
* * generic/tclNamesp.c (NamespaceInscopeCmd): [namespace inscope]dgp2006-01-091-4/+6
| | | | | * tests/namespace.test: commands were not reported by [info level] [Bug 1400572].
* * unix/tcl.m4 (Darwin): add 64bit support, check for Tiger copyfile(),das2005-11-271-9/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | add CFLAGS to SHLIB_LD to support passing -isysroot in env(CFLAGS) to configure (flag can't be present twice, so can't be in both CFLAGS and LDFLAGS during configure), don't use -prebind when deploying on 10.4, define TCL_IO_TRACK_OS_FOR_DRIVER_WITH_BAD_BLOCKING (rdar://3171542). (SC_ENABLE_LANGINFO, SC_TIME_HANDLER): add/fix caching, fix obsolete autoconf macros. Sync with tk/unix/tcl.m4. * unix/configure.in: fix obsolete autoconf macros, sync gratuitous formatting/ordering differences with tk/unix/configure.in. * unix/Makefile.in: add CFLAGS to tclsh/tcltest link to make executable linking the same as during configure (needed to avoid loosing any linker relevant flags in CFLAGS, in particular flags that can't be in LDFLAGS). Avoid concurrent linking of tclsh and compiling of tclTestInit.o or xtTestInit.o during parallel make. (checkstubs, checkdoc, checkexports): dependency and Darwin fixes (dist): add new macosx files. * unix/tclLoadDyld.c (TclpDlopen): use NSADDIMAGE_OPTION_WITH_SEARCHING on second NSAddImage only. [Bug 1204237] (TclGuessPackageName): should not be MODULE_SCOPE. (TclpLoadMemory): ppc64 and endian (i386) fixes, add support for loading universal (fat) bundles from memory. * unix/tclUnixFCmd.c: * macosx/tclMacOSXFCmd.c: ppc64 and endian (i386) fixes. (TclMacOSXCopyFileAttributes): add support for new Tiger copyfile() API to enable copying of xattrs & ACLs by [file copy]. * generic/tcl.h: add Darwin specifc configure overrides for TCL_WIDE defines to support fat compiles of ppc and ppc64 at the same time, (replaces Darwin CVS fix by emoy, rdar://3693001). add/correct location of version numbers in macosx files. * generic/tclInt.h: clarify fat compile comment. * unix/tclUnixPort.h: add Darwin specifc configure overrides to support fat compiles, where configure runs only once for multiple architectures (replaces Darwin CVS fix by emoy, rdar://3693001). * macosx/tclMacOSXBundle.c: * macosx/tclMacOSXNotify.c: * unix/tclUnixNotfy.c: * unix/tclUnixPort.h: fix #include order to support compile time override of HAVE_COREFOUNDATION in tclUnixPort.h when building for ppc64 * macosx/Tcl.pbproj/default.pbxuser (new file): * macosx/Tcl.pbproj/jingham.pbxuser: * macosx/Tcl.pbproj/project.pbxproj: * macosx/Tcl.xcode/default.pbxuser (new file): * macosx/Tcl.xcode/project.pbxproj (new file): * macosx/Tcl.xcodeproj/default.pbxuser (new file): * macosx/Tcl.xcodeproj/project.pbxproj (new file): new/updated projects for Xcode 2.2 on 10.4, Xcode 1.5 on 10.3 & ProjectBuilder on 10.2, with native tcltest targets and support for universal (fat) compiles. * macosx/README: clarification/cleanup, document new Xcode projects and universal (fat) builds via CFLAGS (i.e. all of ppc ppc64 i386 at once). * unix/Makefile.in: * unix/aclocal.m4: * unix/configure.in: * unix/dltest/Makefile.in: * macosx/configure.ac (new file): add support for inclusion of unix/configure.in by macosx/configure.ac, allows generation of a config headers enabled configure script in macosx (required by Xcode projects). * macosx/GNUmakefile: rename from Makefile to avoid overwriting by configure run in tcl/macosx, add support for reusing configure cache, build target fixes, remove GENERIC_FLAGS override now handled by tcl.m4. * generic/tcl.decls: add Tcl_Main declaration as comment to avoid 'checkstubs' target complaining about it missing from stubs. * generic/regex.h: * generic/tclDate.c: * generic/tclEnv.c: * generic/tclGetDate.y: * generic/tclIOUtil.c: * generic/tclObj.c: * generic/tclStubInit.c: * generic/tclStubLib.c: * generic/tclPathObj.c: * generic/tclThreadAlloc.c: * generic/tclThreadStorage.c: * generic/tclTrace.c: * generic/tclVar.c: * generic/tommath.h: * tools/fix_tommath_h.tcl: * unix/tclUnixFCmd.c: ensure externally visible symbols not contained in stubs table are declared as MODULE_SCOPE (or as static if not used outside of own source file). These changes allow 'make checkstubs' to complete without error on Darwin with gcc 4. * generic/rege_dfa.c (getvacant): * generic/regexec.c (cfind): * generic/tclCompExpr.c (CompileSubExpr): * generic/tclNamesp.c (NamespaceEnsembleCmd): * unix/tclUnixChan.c (TclUnixWaitForFile): initialise variables to silence gcc 4 warnings. * generic/tclExecute.c (TclExecuteByteCode): fix unused variable warning when NO_WIDE_TYPE is defined. * generic/regguts.h: only #define NDEBUG if not already #defined. * unix/tclUnixNotfy.c: * macosx/tclMacOSXNotify.c: sync whitespace & comments. * unix/tclUnixPort.h: * win/tclWinPort.h: remove declaration of obsolete&unused TclpMutex API. * unix/configure: * unix/tclConfig.h.in: regen.
* * generic/tclInt.h:Miguel Sofer2005-11-141-5/+10
| | | | | | | | | * generic/tclNamesp.c: * tests/namespace.test: fix for bugs #1354540 and #1355942. The new tests 7.3-6 and the modified 51.13 fail due to the unrelated [Bug 1355342] * tests/trace.test: added tests 20.13-16 for [Bug 1355342]
* Partial fix for [Bug 1355342]dkf2005-11-121-350/+350
| | | | Also ANSIfy the rest of the file
* * generic/tclInt.h:Miguel Sofer2005-11-041-11/+11
| | | | | | | | * generic/tclNamesp.c: * generic/tclVar.c: * tests/trace.test: fix for [Bugs 1338280/1337229]; changed to use the same approach as the 8.4 patch in the ticket (i.e., removed the patch committed on 2005-31-10).
* * generic/tclNamesp.c: fix for [Bugs 1338280/1337229]. Thanks Don.Miguel Sofer2005-10-311-10/+10
| | | | * tests/trace.test: fix duplicate test numbers
* * generic/tclBasic.c: Updated several callers to usedgp2005-09-141-24/+17
| | | | | | | * generic/tclCmdMZ.c: TclFormatToErrorInfo(). * generic/tclIOUtil.c: * generic/tclNamesp.c: * generic/tclProc.c:
* Remove _ANSI_ARGS_ and tidy up commentsdkf2005-08-261-236/+208
|
* Fix crashes when running Snit's test suite caused by traces forcing the interpdkf2005-08-261-2/+5
| | | | result object to become shared.
* * generic/tclNamesp.c (TclTeardownNamespace): Re-ordering so thatdgp2005-07-261-18/+18
| | | | | * tests/trace.test (trace-34.4): command delete traces fire while the command still exists. [Bug 1047286]
* Getting more systematic about styledkf2005-07-171-207/+241
|
* Whitespace/comment tidyingdkf2005-07-151-931/+914
|
* * generic/tclNamesp.c: Allow for [namespace import] of a commanddgp2005-07-051-1/+10
| | | | | * tests/namespace.test: over a previous [namespace import] of itself without throwing an error. [RFE 1230597]
* * generic/tclInt.h: Reduced the Tcl_ObjTypes "index",dgp2005-06-071-6/+6
| | | | | | | * generic/tclIndexObj.c: "enembleCmd", "localVarName", and * generic/tclNamesp.c: "levelReference" to file static scope. * generic/tclProc.c: * generic/tclVar.c:
* TIP#229 implementationdkf2005-05-301-26/+348
|
* Quell a gcc warningdkf2005-05-191-4/+5
|
* Merged kennykb-numerics-branch back to the head; TIPs 132 and 232Kevin B Kenny2005-05-101-1/+1
|
* * generic/tclInt.decls: Converted TclMatchIsTrivial to a macro.dgp2005-05-051-87/+130
| | | | | | | | | | | | | | * generic/tclInt.h: * generic/tclUtil.c: * generic/tclIntDecls.h: `make genstubs` * generic/tclStubInit.c: * generic/tclBasic.c: Added callers of TclMatchIsTrivial where * generic/tclCmdIL.c: a search can be done more efficiently * generic/tclCompCmds.c:when it is recognized that a pattern match * generic/tclDictObj.c: is really an exact match. [Patch 1076088] * generic/tclIO.c: * generic/tclNamesp.c: * generic/tclVar.c:
* Fix commentdkf2005-03-091-1/+2
|
* TIP#235 implementation (rename functions, add to stubs table, document)dkf2005-01-191-72/+73
| | | | Ensembles now have a C API. :^)
* * generic/tclTest.c: Added two new functions to allocate memoryMiguel Sofer2004-12-151-13/+66
| | | | | | | | | | from the execution stack (TclStackAlloc, TclStackFree). Added functions TclPushStackFrame and TclPopStackFrame that do the work of Tcl_PushCallFrame and Tcl_PopCallFrame, but using frames allocated in the execution stack - i.e., heap instead of C-stack. The core uses these two new functions exclusively; the old ones remain for backwards compat, as at least two popular extensions (itcl, xotcl) are known to use them.
* converting the static function GetNamespaceFromObj() to MODULE_SCOPEMiguel Sofer2004-12-111-12/+9
| | | | TclGetNamespaceFromObj().
* Make ensemble API available to rest of Tcl core.dkf2004-12-101-35/+1
|
* Provide an internal API for manipulating ensembles.dkf2004-12-091-133/+635
|
* Convert mutex-protected global state into thread-local state. [FRQ 1077210]dkf2004-12-021-9/+18
|
* Cleaning up of the namespace guts.dkf2004-11-011-551/+546
|
* Allow ensembles to rewrite their subcommands' error messages to be moredkf2004-10-291-14/+66
| | | | | | relevant to users. [Patch 1056864] Also patches to core to take advantage of this Also other general cleaning up of Tcl_WrongNumArgs usage
* Make ensembles report shorter error traces that conceal more of how thedkf2004-10-221-2/+3
| | | | ensemble implements itself. This is usually the right thing to do.
* * generic/tclBasic.c (Tcl_CreateInterp,Tcl_DeleteInterp,dgp2004-10-151-49/+105
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | TclEvalObjvInternal,Tcl_LogCommandInfo,TclAddObjErrorInfo): * generic/tclCmdAH.c (Tcl_CatchObjCmd): * generic/tclEvent.c (BgError,ErrAssocData,Tcl_BackgroundError, HandleBgErrors,BgErrorDeleteProc): * generic/tclExecute.c (TclCreateExecEnv,TclDeleteExecEnv): * generic/tclIOUtil.c (comments only): * generic/tclInt.h (ExecEnv,Interp, ERR_IN_PROGRESS): * generic/tclInterp.c ([tclInit]): * generic/tclMain.c (comments only): * generic/tclNamesp.c (Tcl_CreateNamespace,Tcl_DeleteNamespace,TclTeardownNamespace): * generic/tclProc.c (TclUpdateReturnInfo): * generic/tclResult.c (Tcl_ResetResult,TclTransferResult): * generic/tclTrace.c (CallVarTraces): Reworked management of the "errorInfo" data of an interp. That information is now primarily stored in a new private (Tcl_Obj *) field of the Interp struct, rather than using a global variable ::errorInfo as the primary storage. The ERR_IN_PROGRESS flag bit value is no longer required to manage the value in its new location, and is removed. Variable traces are established to support compatibility for any code expecting the ::errorInfo variable to hold the information. ***POTENTIAL INCOMPATIBILITY*** Code that sets traces on the ::errorInfo variable may notice a difference in timing of the firing of those traces. Code that uses the value ERR_IN_PROGRESS.
* * generic/tclBasic.c:dgp2004-10-061-61/+55
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * generic/tclBinary.c: * generic/tclCmdAH.c: * generic/tclCmdIL.c: * generic/tclCmdMZ.c: * generic/tclCompExpr.c: * generic/tclDictObj.c: * generic/tclEncoding.c: * generic/tclExecute.c: * generic/tclFCmd.c: * generic/tclHistory.c: * generic/tclIndexObj.c: * generic/tclInterp.c: * generic/tclIO.c: * generic/tclIOCmd.c: * generic/tclNamesp.c: * generic/tclObj.c: * generic/tclPkg.c: * generic/tclResult.c: * generic/tclScan.c: * generic/tclTimer.c: * generic/tclTrace.c: * generic/tclUtil.c: * generic/tclVar.c: It is a poor practice to directly set or append to the value of the objResult of an interp, because that value might be shared, and in that circumstance a Tcl_Panic() will be the result. Searched for example of this practice and replaced with safer alternatives, often using the Tcl_AppendResult() routine that dkf just rehabilitated.
* * generic/tclBasic.c (Tcl_CreateInterp,Tcl_DeleteInterp,dgp2004-10-051-14/+68
| | | | | | | | | | | | | | | | | | | | TclEvalObjvInternal,Tcl_LogCommandInfo): * generic/tclCmdAH.c (Tcl_CatchObjCmd): * generic/tclEvent.c (BgError,Tcl_BackgroundError,HandleBgErrors): * generic/tclInt.h (Interp, ERROR_CODE_SET): * generic/tclNamesp.c (Tcl_CreateNamespace,Tcl_DeleteNamespace,TclTeardownNamespace): * generic/tclResult.c (Tcl_ResetResult,Tcl_SetObjErrorCode,TclTransferResult): * generic/tclTrace.c (CallVarTraces): Reworked management of the "errorCode" data of an interp. That information is now primarily stored in a new private (Tcl_Obj *) field of the Interp struct, rather than using a global variable ::errorCode as the primary storage. The ERROR_CODE_SET flag bit value is no longer required to manage the value in its new location, and is removed. Variable traces are established to support compatibility for any code expecting the ::errorCode variable to hold the information.
* oopsdgp2004-10-051-2/+1
|