Skip to content
Tcl Source Code Artifact [0f0aba22e7]
Login

Artifact [0f0aba22e7]

Artifact 0f0aba22e7cb7c4ec70ee4965c4d44e2280b5f1a:

Ticket change [0f0aba22e7] - New ticket [2995655fffffffff|2995655fff] <i>Report inner contexts in [info errorstack]</i>. by ferrieux on 2010-05-02 23:24:04.
D 2010-05-02T23:24:04
J assignee dgp
J cmimetype text/plain
J comment In\sTIP\s#348,\snow\saccepted\sand\scommitted,\sthe\serror\sstack\sreports\sa\slist\sof\sargslists\sfor\sprocedure\scalls,\salong\swith\suplevel\soffsets.\nHowever,\sit\shas\sbeen\snoted\sthat\sthe\sdeepest\sargslist,\saka\sthe\s"inner\scontext",\sie\sthe\sbytecode\sinstruction\sand\sthe\sarguments\sit\sused\soff\sthe\sstack\sbefore\sdeciding\sto\sraise\san\serror,\sare\snot\sreported.\sThis\sis\sfrustrating,\stypically\swhen\s[expr]\swith\sa\scomplex\sexpression\sraises\san\serror\slike\s"domain\serror:\sargument\snot\sin\svalid\srange".\n\nThe\sattached\spatch,\sdesigned\safter\sadvice\sfrom\sMiguel,\sovercomes\sthis\slimitation\sby\sinserting\s(when\spossible)\sat\sthe\sbeginning\sof\sthe\serrorstack:\n\n\s\s\s\sINNER\s{name_of_instruction\sarg1\sarg2\s...\sargN}\n\nfor\sexample:\n\n\s\s\s\s%\sproc\sf\s{x\sy}\s{expr\s{log($x)+acos($y)}}\n\s\s\s\s%\sf\s1\s2\n\s\s\s\sdomain\serror:\sargument\snot\sin\svalid\srange\n\s\s\s\s%\sinfo\serrorstack\n\s\s\s\s\sINNER\s{invokeStk1\stcl::mathfunc::acos\s2}\sCALL\s{f\s1\s2}\n\nA\sfew\snotes\son\sthe\simplementation:\n(1)\sthe\simpact\son\sTEBC\sis\sintentionally\sminimal\s(gentle\sarm\stwisting,\sMig\s;-):\sa\ssingle\sline,\ssaving\sthe\spc\sin\sanother\slocal.\n(2)\sonly\sthose\sINSTs\swhere\sthe\sargc\sis\sreadily\scomputable,\sgenerate\sa\snontrivial\sinner\scontext\sreport.\sOthers\sare\suntouched,\sjust\slike\snon-TEBC\serror\ssites.\n(3)\sthe\s'knowledge\sbase'\sgiving\sthe\salgorithm\sfor\scounting\sthe\sargc\sis\sa\ssingle\sswitch()\sblock\smimicking\sa\stiny\spart\sof\sTEBC,\sbut\swhich\scan\sevolve\smuch\sslower,\ssince\sthe\sdefault\sis\sto\sreport\sonly\sthe\sinstruction\sname.\sHence\sno\sneed\sto\s'keep\sin\ssync'\stoo\stightly.\sThis\sshould\sfree\sthe\smind\sof\sthose\swho\swant\sto\sinnovate\sin\sTEBC...\n(4)\sat\sthis\sstage,\sthere's\sroom\sfor\soptimization,\slike\spre-computing\sand\ssharing\sthe\sinstruction-name\sliterals,\sand\salso\sreusing\sthe\slist\sstorage\sfor\sthe\sinner\scontext,\sjust\slike\swas\sdone\sfor\sthe\serror\sstack\sitself.\n\nHigh\sprio\sbecause\sit\sis\san\sextension\sthat\shas\sbeen\sasked\sfor\sduring\sthe\sTIP\sdiscussion,\sthe\sTIP\sis\svery\syoung,\sand\sa\smilestone\srelease\sis\sapproaching...
J foundin None
J is_private 0
J priority 9\sImmediate
J resolution None
J status Open
J submitter ferrieux
J subsystem None
J title Report\sinner\scontexts\sin\s[info\serrorstack]
J type Patch
K 2995655fffffffffffffffffffffffffffffffff
U ferrieux
Z 6c353d1980c2bba4e7092a6b1319131f