<i>Stop using deprecated Tcl_VarEval()</i> status still Open with 4 other changes
by
.
D 2016-03-08T18:17:41.028
J assignee jan.nijtmans
J icomment \r\nThe\sproposed\srevision\shas\sbeen\swritten\sto\r\nreproduce\sthe\sbehavior\sof\sthe\sTcl_VarEval()\r\ncall,\swhich\sin\sthe\slong\srun\smay\snot\sbe\sthe\r\nbest\sidea.\r\n\r\nThe\sTcl_VarEval()\sroutine\sbuilds\sand\sevaluates\r\na\sscript,\snot\sa\scommand.\s\sAlthough\sfor\ssome\stime\r\nwe've\sbeen\sdocumenting\sthat\sserver\ssocket\saccept\r\ncallbacks\sare\ssingle\scommands,\sthe\simplementation\r\nhas\snever\sagreed.\s\sSee\r\n\r\nhttp://core.tcl.tk/tcl/info/2957688\r\n\r\nPossibly\smuch\sworse,\sthere\sis\sno\scontrol\sin\splace\r\nto\sdetermine\sthe\scontext\sof\sthe\scallback\sscript\r\nevaluation.\s\sIt\sis\sevaluated\sin\swhatever\scontext\r\nis\scurrent\sin\sthe\sinterp,\swhether\sthat\sbe\sa\snamespace,\r\nor\sthe\sbody\scontext\sof\ssome\sinvocation\sof\ssome\sproc.\r\nMost\scallbacks\sin\sTcl\sare\sforced\sto\sevaluate\sin\sglobal\r\ncontext\sfor\spredictable\sbehavior.\s\sIt's\ssurprising\sto\sme\r\nthat's\snot\sbeen\sdone\swith\sserver\ssocket\saccept\scallbacks,\r\nbut\sTcl_VarEval()\sjust\sevaluates\swhere\sit\sis.\r\n\r\nIt\swould\sbe\seasy\sto\schange\sthis\sin\sthe\srevised\simplementation\r\nby\sjust\sadding\sthe\sTCL_EVAL_GLOBAL\sflag\sto\sthe\r\nTcl_EvalObjEx()\scall.\s\sI\scan't\sthink\sof\sa\sgood\sreason\snot\r\nto\smake\sthis\schange\snow\sthat\sit's\seasy.\r\n\r\nReview\sand\scomment\sinvited.
J login dgp
J mimetype text/plain
K 0b8c387cf7c00a93796ad267891bc3d691c07b78
U dgp
Z 6a7a658217545218ca1c5e06a0fc343a