.
D 2001-01-26T00:18:44
J assignee nobody
J cmimetype text/plain
J comment \nthis\sis\sa\spatch\sfor\swhich\si\sdidn't\ssee\sany\srelated\sPR,\sso\si'm\snot\sentirely\scertain\sif\sthis\spatch\swill\sbe\sa\spopular\sone\sor\snot...\n\nas\smentioned\sin\spatch#103420,\smy\scompany's\stools\stypically\sregister\sa\scallback\swith\sTcl_CreateTrace()\sso\sthat\swe\scan\sautomatically\sgenerate\sa\scommand\s\s"history\slog"\sor\s"replay\sscript"\sof\sa\stool's\susage.\s\sone\sof\sthe\sproblems\swe've\shad\swith\sthe\stcl\strace\sinvolves\sthe\s'level'\sargument\sthat\sgets\spassed\sto\sour\strace\scallback\sfunction.\s\sspecifically,\sbracketed\scommands\swhose\sresults\sare\spassed\sas\sarguments\sto\sanother\scommand\sis\sthe\sissue.\s\s\n\nconsider\stwo\stcl\scommands,\s'a'\sand\s'b',\swhere\sthe\sresults\sof\s'b'\sare\scommonly\spassed\sas\san\sargument\sto\s'a'.\s\sie,\s"a\s[\sb\s]".\s\swith\stoday's\simplementation,\sa\stcl\strace\scallback\swill\sbe\sinvoked\stwice,\sonce\swith\sthe\s'command'\sargument\sequal\sto\s"b",\sand\sthen\sagain\swith\s'command'\sequal\sto\s"a\s[\sb\s]".\s\sthe\s'level'\sargument\sin\sboth\sinvocations\sis\sthe\s*same*\svalue,\swhich\spresents\sa\sproblem\sfor\sme.\s\sif\sthe\s'level'\sprovided\sin\sthe\sfirst\sinvocation\swas\s'X',\si\swould\sexpect\sthe\ssecond\sinvocation\sto\sbe\s'X-1'.\s\sotherwise,\si\shave\sno\sway\sof\stelling\sthat\sthe\sfirst\sinvocation\sis\smerely\sbeing\sevaluated\sas\sanother\scommand's\sargument.\n\nsince\sthe\sbracketed\scommand\scannot\sbe\sdistinguished\sfrom\sa\sregular\scommand,\sour\sresulting\scommand\slog\sis\sfaulty\sin\sthat\sit\swill\sfirst\sprint\s'b'\sand\sthen\sprint\s'a\s[\sb\s]'.\s\s\n\nthe\sfix\sfor\sthis\sinvolves\swrapping\san\sincrement/decrement\sof\siPtr->numLevels\sbefore/after\sa\scall\sto\sa\sbracketed\scommand.\s\si'm\snot\sconvinced\sthe\spatch\si've\sprovided\sbelow\sis\sthe\sabsolute\scleanest\sor\sbest\sway\sto\sachieve\sour\sgoal,\sbut\sit\sseems\sto\swork\sjust\sfine\sfor\sus.\n\nit'd\sbe\snice\sto\ssee\sthis\spatch\sencorporated\sinto\sa\sfuture\srelease\sof\stcl,\sbut\si\salso\srealize\sthere\smay\sbe\ssome\sargument\sto\sthe\scontrary\sthat\si\shaven't\sseen\syet...\n
J foundin None
J priority 5\sMedium
J resolution None
J status Open
J submitter daknol
J subsystem
J title Tcl_CreateTrace()\scallback\s-\sa\sproposed\s'enhancement'
J type Patch
K 403430ffffffffffffffffffffffffffffffffff
U daknol
Z 6a411176ad9b778295b354bff25b7795