<i>lappend inconsistency with respect to read traces</i> status still Open with 4 other changes
by
.
D 2010-09-02T00:46:01
J icomment Notes\sfrom\sthe\sdiscussion\sof\sthe\sproblem\s...\n==================================\n\n[JH]\sThere\sis\sa\srelated\sset\sof\scomments\sin\sappend.test\saround\sthis\sbehavior\schange:\n\n\s\s\s\s#\sThe\sbehavior\sof\sread\striggers\son\slappend\schanged\sin\s8.0\sto\n\s\s\s\s#\snot\strigger\sthem,\sand\swas\schanged\sback\sin\s8.4.\n\nThis\sof\scourse\sadversely\seffects\s::env,\swhich\shas\sa\sbuilt-in\sread\strace\sthat\serrors\son\sunknown\svars.\s\sSo\swhy\sdoes\sthe\sfirst\scase\snot\serror\sin\s8.4?\s\sApparently\sthe\sfix\sto\slappend\sonly\skicked\sin\sfor\sthe\sfully\sbyte-compiled\scase.\sThat\smeans\splacing\sit\sstraight\sin\sa\sproc,\sor\sin\san\sif/else\syou\swould\ssee\sthe\schange,\sbut\s'switch'\swasn't\sbyte-compiled\suntil\s8.5.\n\nAt\sthis\spoint,\sI\sdon't\sknow\swhat\sthe\sbest\sresolution\sis.\s\sThe\sintention\sof\sthe\schange\swas\sto\sallow\sread\straces\sto\strigger\swith\slappend.\s\s::env\shas\sa\sread\strigger\sthat\serrors\son\sunknown\svariable\sreads.\s\sThis\swas\snew\sin\s8.4,\sbut\sagain\smasked\sby\scode\sthat\sdidn't\suse\sthe\sbyte-compiled\sversion.\n\n==================================\n\n[HL]\sHi\sJeff,\n\nI\shave\smodified\syour\sexample\sbit\smore\s...\sThe\stest1\spasses\sin\stcl8.5\sbut\stest2\sfails.\sIt\sseems\sthat\sthe\sbehavior\schanges\swhether\s--\sswitch\sis\sspecified\safter\s-exact\sor\snot.\sIf\sI\sdo\snot\sspecify\sthe\s-exact\sswitch,\sthen\sit\sfails\sfor\sboth\sin\stcl8.5.\sSo\sthe\s"--"\soption\sseems\sto\sbe\schanging\sits\sbehavior.\n\nOk,\sassuming\sthat\sthis\sis\sthe\sintended\sbehavior\s--\swhat\sabout\sregular\sarray\svariables?\sShouldn't\sit\sbehave\sthe\ssame\sif\sI\sdefine\sa\sread\strace\son\sglobal\sarray\sx\swith\sno\selements\sdefined\sfor\sit\sbut\suse\slappend\sto\sadd\svalue\sto\sit.\n\nproc\stest\s{var\soper\selem\svalue}\s\s{\n\s\sswitch\s-exact\s--\s$oper\s{\sadd\s{\slappend\s[set\svar]($elem)\s$value\s}\s}\n}\nproc\sfoo\sargs\s{puts\s$args}\ntrace\sadd\svariable\s::x\sread\sfoo\ntest\s::x\sadd\skey\s"new\svalue"\ntest\s::env\sadd\skey\s"new\svalue"\n\nIt\sdoesn't\sseem\sto\sthrow\sany\serror\sfor\sother\stcl\svariables.\sSo\swhy\sis\sonly\s::env\svariable\streated\sspecially.\s\n\n
J login andreas_kupries
J mimetype text/plain
J username andreas_kupries
K 3057639fffffffffffffffffffffffffffffffff
U andreas_kupries
Z 681f7abe58bbd41740965d49fe364732