.
D 2016-11-23T21:42:28.051
J assignee nobody
J closer nobody
J cmimetype text/x-fossil-wiki
J comment <h2>Background</h2>\r\nI\swas\stalking\sto\sNathan\sCoulter\sat\sthe\sTcl\sconference\sand\she\swas\stelling\sme\sabout\ssome\sof\sthe\sthings\sthat\sare\sdone\sin\sRivet\sand\sNaviServer\sto\sget\sspeed.\sIn\sparticular,\she\swas\sdoing\shorrible\sthings\sto\stry\sto\sclone\sa\snamespace;\sit\swas\sa\ssignificant\sbottleneck.\sI\smentioned\sthat\sTclOO\scan\sclone\snamespaces\s(imperfectly)\sand\sspeculated\sthat\s<tt>oo::copy</tt>\smight\sbe\sa\suseful\stool.\sAnd\sindeed\sit\smight,\sexcept\sthat\sexisting\scode\srequires\sthat\sthe\screated\snamespace\shave\sa\sparticular\sname\s(<tt>::request</tt>\sif\sI\sremember\sright)\sand\s<tt>oo::copy</tt>\sdoesn't\sallow\sspecifying\sthe\sname\sof\sthe\screated\snamespace,\seven\sthough\sthe\sunderlying\sC\sAPI\sfor\sobject\scopying\s(<tt>Tcl_CopyObjectInstance</tt>)\sdoes.\r\n<h2>Feature\sRequest</h2>\r\nAdd\san\sextra\soptional\sargument\sto\s<tt>oo::copy</tt>\sto\sallow\sspecifying\sthe\starget\sobject\snamespace.\sIf\somitted,\sthe\scurrent\sbehaviour\sshould\sbe\sused.\sIf\spresent,\sit\smust\sbe\sin\sa\sform\sacceptable\sto\s<tt>Tcl_CreateNamespace</tt>\sand\s<i>must\snot\srefer\sto\san\sexisting\snamespace</i>;\sthe\sname\sof\sthe\sclone\sobject's\snamespace\swill\sbe\sthe\sgiven\svalue\s(instead\sof\sthe\sdefault,\sarbitrary\sone).\sThis\swill\smake\s<tt>oo::copy</tt>\shave\stwo\soptional\sarguments,\sinstead\sof\sthe\scurrent\ssingle\sone.\r\n<dl><dd><tt><b>oo::copy</b>\s<i>sourceObject</i>\s?<i>targetObject</i>?\s?<i>targetNamespace</i>?</tt></dd></dl>\r\n<h2>Implementation\sNotes</h2>\r\nThe\sbasic\sfunctionality\sis\salready\sthere\sat\sthe\sC\slevel;\sthis\sis\sjust\sexposing\sit\sto\sthe\sTcl\slevel\s(and\stesting/documenting).
J is_private 0
J login dkf
J priority 5\sMedium
J resolution None
J severity Minor
J status Open
J submitter dkf
J subsystem 35.\sTclOO\sPackage
J title oo::copy\sneeds\san\soptional\snamespace\sparameter
J type RFE
K dd3b844fdabdeae5fcb07f4a16d1c62ae5fa75ac
U dkf
Z afea6e6586452fa52e86ba0b4c5ec510