summaryrefslogtreecommitdiffstats
path: root/generic/tclListObj.c
Commit message (Collapse)AuthorAgeFilesLines
* Export stubs for libtommath; fix mingw compiler warningsKevin B Kenny2005-12-131-2/+2
|
* * generic/tclListObj.c: Restored the SetListFromAny routine todgp2005-11-181-2/+2
| | | | | | | * generic/tclObj.c: the "list" Tcl_ObjType, and restored the Tcl_RegisterObjType() call for "list". This addresses the needs of some "bridge" extensions to examine whether the Tcl_ObjType of a Tcl_Obj is that of the "list" Tcl_ObjType.
* More bits of ANSIfyingdkf2005-11-111-115/+123
|
* * generic/tclListObj.c (TclLsetFlat):Miguel Sofer2005-10-201-5/+22
| | | | | * tests/lset.test (lset-10.3): fixed handling of unshared lists with shared sublists, [Bug 1333036] reported by neuronstorm.
* Add flag to lists so that evaluating contexts can handle them efficiently muchdkf2005-09-061-45/+63
| | | | | of the time even when they are not pure. The flag works by keeping track of when the string rep was derived from the internal rep.
* * unix/tclUnixSock.c (InitializeHostName): Synchronized use ofandreas_kupries2005-09-021-2/+2
| | | | | | | | | | | | | | | | | | | | | | | static modifier in declaration and definition of function. * unix/tclUnixChan.c (FileTruncateProc): Synchronized use of static modifier in declaration and definition of function. * generic/tclResult.c (ReleaseKeys): Synchronized use of static modifier in declaration and definition of function. * generic/tclListObj.c (NewListIntRep): Synchronized use of static modifier in declaration and definition of function. * generic/tclEncoding.c (InitializeEncodingSearchPath): Synchronized use of static modifier in declaration and definition of function. * generic/tclEncoding.c (FillEncodingFileMap): Synchronized use of static modifier in declaration and definition of function. * generic/tclIORChan.c (RcNewHandle): Synchronized use of static modifier in declaration and definition of function.
* Better to panic sanely than to crash with a bad memory access. [Bug 1267380]dkf2005-08-251-1/+7
|
* Getting more systematic about styledkf2005-07-191-317/+317
|
* Merged kennykb-numerics-branch back to the head; TIPs 132 and 232Kevin B Kenny2005-05-101-1/+1
|
* * generic/tclListObj.c (Tcl_ListObjIndex): added missing NULL returndas2005-04-091-2/+3
| | | | when getting index from an empty list.
* Changed the internal representation of lists to (a) reduce the malloc/freeMiguel Sofer2005-04-021-475/+396
| | | | | | | | calls at list creation (from 2 to 1), (b) reduce the cost of handling empty lists (we now never create a list internal rep for them), (c) allow refcounting of the list internal rep. The latter permits insuring that the pointers returned by Tcl_ListObjGetElements remain valid even if the object shimmers away from its original list type. This is [Patch 1158008]
* * generic/tclListObj.c (Tcl_ListObjReplace): use memmove() insteaddas2004-11-111-12/+4
| | | | | | | | | | | of manual copy loop to shift list elements. Decreases time spent in Tcl_ListObjReplace() from 5.2% to 1.7% of overall runtime of tclbench on a ppc 7455 (i.e. 200% speed increase). [Patch 1064243] * generic/tclHash.c: hoisted some constant pointer dereferences out of loops to eliminate redundant loads that the gcc optimizer didn't deal with. Decreases time spend in Tcl_FindHashEntry() by 10% over a full run of the tcl testuite on a ppc 7455. [Patch 1064243]
* Factorize out the code for freeing an object's internal rep.dkf2004-09-291-10/+3
|
* All uses of 'panic' (the macro) changeddavygrvy2003-12-241-11/+11
| | | | | | | to 'Tcl_Panic' (the function). The #define of panic in tcl.h clearly states it is deprecated in the comments. [Patch 865264]
* When copying and pasting code, check that argument types are sensible! <:^)dkf2003-11-011-5/+5
|
* Increased robustness and speed for [lrepeat] with help of new list constructordkf2003-11-011-1/+115
|
* Whitespace policedkf2003-10-301-163/+132
|
* * doc/SplitList.3: Implementation of TIP 148. Fixes [Bug 489537].dgp2003-09-041-2/+3
| | | | | | | | | | * generic/tcl.h: Updated Tcl_ConvertCountedElement() to quote * generic/tclUtil.c: the leading "#" character of all list elements unless the TCL_DONT_QUOTE_HASH flag is passed in. * generic/tclDictObj.c: Updated Tcl_ConvertCountedElement() callers * generic/tclListObj.c: to pass in the TCL_DONT_QUOTE_HASH flags * generic/tclResult.c: when appropriate.
* * generic/tclEvent.c (TclInExit):dgp2002-01-071-7/+7
| | | | | | | * generic/tclIOUtil.c (SetFsPathFromAbsoluteNormalized, SetFsPathFromAny,Tcl_FSNewNativePath,DupFsPathInternalRep): * generic/tclListObj.c (TclLsetList,TclLsetFlat): Added some type casts to satisfy picky compilers.
* * generic/tclCkalloc.c (MemoryCmd, TclFinalizeMemorySubsystem):dgp2001-12-281-4/+4
| | | | | | | | | | | | | | | | | | | Added the [memory onexit] command, intended to replace [checkmem]. * doc/DumpActiveMemory.3: * doc/memory.n: Updated documentation for [memory] and related matters. [Bug 487677] * mac/tclMacBOAMain.c (Tcl_Main, CheckmemCmd): Removed all the machinery for the [checkmem] command that is completely duplicated by code in generic/tclCkalloc.c. * generic/tclBinary.c: * generic/tclListObj.c: * generic/tclObj.c: * generic/tclStringObj.c: Removed references to [checkmem] in comments, referencing [memory active] instead, since it is documented.
* Removed a rogue C++ comment that inadvertently got left in tclListObj.cKevin B Kenny2001-11-161-2/+2
|
* Reference implementation of TIP's #22, #33 and #45. Adds thehobbs2001-11-141-16/+614
| | | | | | ability of the [lindex] command to have multiple index arguments, and adds the [lset] command. Both commands are byte-code compiled. [Patch #471874] (work by Kenny, commited by Hobbs)
* (TIP#27) Changed a number of Tcl API's to accept "CONST char*"Kevin B Kenny2001-04-041-3/+3
| | | | in place of simple "char*". (kennykb) [Patch #404026]
* * generic/tclListObj.c (Tcl_SetListObj): set objPtr->length = 0 inhobbs2001-04-041-1/+2
| | | | | empty object case to maintain sanctity of Tcl_Obj bytes/length pairing. (porter) [Patch #405998]
* Rolled back changes to change the prototype ofredman1999-08-101-2/+2
| | | | Tcl_ListObjGetElements()
* * generic/tclListObj.c:core_8_2_b3_baseredman1999-08-101-2/+2
| | | | | | | | | | | | | | | | * generic/tcl.decls: * generic/tclDecls.h: Applied patch from Jim Ingham to change the prototype of Tcl_ListObjGetElements to have the last argument have a CONST so that you can feed it the objv that you get from the standard TclObj command proc. * generic/tclAlloc.c: * generic/tclCmdIL.c: * generic/tclIO.c: * generic/tclThread.c: * win/tclWinThrd.c: * unix/tclUnixThrd.c: Fixed Brent's changes so that they work on Windows (and he fixed the bug in the Unix thread implementation).
* * mac/tclMacResource.c:stanton1999-04-281-2/+2
| | | | | | | | | * generic/tclListObj.c: * generic/tclObj.c: * generic/tclStringObj.c: Changed to avoid freeing the string representation before freeing the internal rep. This helps with debugging since the string rep will still be valid when the free proc is invoked.
* merged tcl 8.1 branch back into the main trunkstanton1999-04-161-6/+9
|
* Fixed bug in Tcl_SetListObj - it used to create invalid Tcl_Obj if you passedrjohnson1998-10-131-1/+4
| | | | | | in 0 elements. Despite what docs said. Also updated a few copyright notices.
* Replaced SCCS strings, fixed binary filescore_8_0_3stanton1998-09-141-1/+1
|
* Initial revisionrjohnson1998-03-261-0/+1053