Skip to content
Tcl Source Code Artifact [726b73da1c]
Login

Artifact [726b73da1c]

Artifact 726b73da1c1407998ce56d1689085f46c4ed961d:

Ticket change [726b73da1c] - New ticket [1158008fffffffff|1158008fff] <i>new list internal rep</i>. by msofer on 2005-03-07 01:05:59.
D 2005-03-07T01:05:59
J assignee kennykb
J cmimetype text/plain
J comment Attached\sa\spatch\sagainst\sHEAD\sthat\schanges\sthe\sinternal\nreps\sof\sobjects.\sThe\schanges\sare:\n\n(1)\sThe\sList\sstruct\sis\snow\sgrowable\sand\scontains\sthe\npointers\sto\sthe\slist\selements\sat\sthe\send.\sThis\sreduces\nthe\snumber\sof\smallocs\sin\slist\screation\sfrom\s2\sto\s1.\n\n(2)\sThe\sList\sstruct\sis\snow\srefcounted.\sThis\spermits\ninsuring\sthat\sthe\spointers\sto\sthe\slist\selements\ssurvive\na\spossible\sshimmering\sof\sthe\sobject\s(by\sincreasing\sthe\nref\scount).\sThis\sis\snow\suse\sin\sTcl_EvalObjEx\s(pure\slist\nopt)\sand\sTclLsetList\s(so\sthat\sit\scalls\sTclLsetFlat)\n\n(3)\sAll\sempty\slists\sin\sa\sthread\sshare\sthe\ssame\sList\ninternal\srep.\sIn\sthis\smanner,\san\sempty\slist\scan\sbe\nallocated\sand\sreserved\swithout\sany\smalloc/free\scalls\n\nThe\spatch\spasses\sthe\stestsuite.\sIt\shas\snot\sbeen\stested\nfor\sleaks\syet.\sThere\sshouldn't\sbe\sany\s...\n\nCAVEAT:\scallers\sof\sTcl_ListObjGetElements\sshould\s*not*\nchange\sthe\selements,\seven\sif\sthe\sTcl_Obj\sis\sunshared\n(as\sits\sinternal\srep\smay\sbe\sshared).\sThis\swas\sIMO\nalready\san\sabuse\sof\sthe\sapi,\sbut\sit\sis\svalid\sin\sthe\nunpatched\simplementation\sand\sinvalid\swith\sthe\spatch.\nThe\sdocs\sare\ssilent\sabout\sthis;\sthey\sdo\snot\seven\nmention\sthat\sthe\sTcl_Obj\sshould\snot\sbe\sshared\sfor\san\nedit\sto\sbe\svalid.\sMaybe\sthrow\ssome\snew\sCONST\sinto\sthat\sapi?
J foundin None
J priority 5\sMedium
J resolution None
J status Open
J submitter msofer
J subsystem 14.\sList\sObject
J title new\slist\sinternal\srep
J type Patch
K 1158008fffffffffffffffffffffffffffffffff
U msofer
Z 2b3aa15c0a377dac1706126b46fc5cca