.
D 2025-03-25T01:14:34.071
J assignee nobody
J closer nobody
J cmimetype text/x-fossil-wiki
J comment The\scommand\sof\sOO-object\swill\sbe\salways\screated\susing\sa\srename/delete\strace,\sthat\shas\sa\slot\sof\sadverse\sconsequences:\r\n<ol>\r\n\s\s<li>additional\salloc/free\sper\sobject</li>\r\n\s\s<li>unneeded\seffort\sby\sdeletion\sdue\sto\suntrace\sprocedure</li>\r\n\s\s<li>tracing\sof\scommand\smay\scause\sextra\soverhead\sby\sevaluation,\sand\sneedlessly\sburden\sthe\sinvocation\sof\sobject\sand\sits\smethods</li>\r\n\s\s<li>due\sto\sthis\sretarded\sby\sdesign\sclean-up\svia\strace\s(and\sonly\sone\srefCount\sfor\scmdPtr\sstored\sin\sobject),\sit\smay\scause\susage\safter\sfree\sfor\sdeleted\soPtr->command\s(with\sTcl_DeleteCommandFromToken,\sif\sit\swas\slast\sreference\sto\sthe\stime\sof\scall\sObjectNamespaceDeleted)</li>\r\n\s\s<li>oPtr->refCount\sis\sinitially\s2,\swith\sfurther\scons,\slike\spotential\sleaks\s(either\strace\sor\scommand\sisn't\sinvolved\sin\sthis\srefCount,\sotherwise\sit'd\sbe\s3\sand\snot\s2)\sor\sdereferencing\sby\sdeletion\sis\snot\sreally\s"atomic"\sor\selse\smay\sbe\ssemi-finished\sby\srefCount\s=\s1;</li>\r\n\s\s<li>the\strace\sis\sbasically\snot\sreally\sneeded,\sbecause:\r\n\s\s<ul>\r\n\s\s\s\s<li>for\sdeletion\sthere\sis\sdeleteProc-callback\sthat\sone\scould\sset\sdirectly\sby\screating\sof\sthe\sOO-command</li>\r\n\s\s\s\s<li>and\srenaming\strace\sis\scurrently\sused\sonly\sto\sclean\soPtr->cachedNameObj\s(if\sit\sis\stherel),\sthis\scan\sbe\sachieved\sby\sdifferent\sapproach,\se.g.\sby\schecking\sof\scmdEpoch\s(which\sgets\sincremented\sby\srename)\sinside\sthe\sTclOOObjectName);</li>\r\n\s\s</ul>\r\n\s\s</li>\r\n</ol>\r\n\r\n\r\nI'll\sprovide\snew\sbranch\swithout\stracing\sin\sOO.
J foundin 8.6+
J is_private 0
J login sebres
J priority 5\sMedium
J private_contact 50e9528765c18296566374b3fde2df942c394efd
J resolution None
J severity Minor
J status Open
J submitter sebres
J subsystem 35.\sTclOO\sPackage
J title OO-command\simplicit\stracing
J type Bug
K ebc39f14d75c1cfc8cd0840f8312b45b4f744b64
U sebres
Z ae0a8e579e78a3170dee8906283a988c