Tcl Source Code

Artifact [f1457e8942]
Login

Artifact f1457e894220a9584b3fdf83f8f9608a032c52d53e85d1e88e50a83ad88112ce:

Ticket change [f1457e8942] - New ticket [2d2a321244] info frame does not correct recognize current type of execution scope. by sebres 2019-03-15 14:18:16.
D 2019-03-15T14:18:16.341
J assignee nobody
J closer nobody
J cmimetype text/x-fossil-wiki
J comment If\sframe\slevel\sis\sprovided\sas\svalue,\sit\sis\sconfused:\r\n<code><pre\sstyle="padding-left:10">\r\n%\sproc\stest\s{}\s{\sputs\spr:[info\sframe\s[info\sframe]];\snamespace\seval\s::test\s{puts\sns:[info\sframe\s[info\sframe]]}\s};\stest\r\n\s\spr:type\sproc\sline\s1\scmd\s{info\sframe\s[info\sframe]}\sproc\s::test\slevel\s0\r\n\s\sns:type\s<b\sstyle="color:red">proc</b>\sline\s1\scmd\s{info\sframe\s[info\sframe]}\slevel\s0\r\n</pre></code>\r\ntotally\sunexpected\stype\s(red\smarked),\simho\s-\sshould\snot\stype\sbe\ssomething\slike\s"eval"\sor\s"namespace"\sin\sthe\ssecond\scase?\r\n\r\nIf\sone\sgives\sthe\s0\s(so\sas\scurrent\sframe\slevel),\sit\sworks\scorrect:\r\n<code><pre\sstyle="padding-left:10">\r\n%\sproc\stest\s{}\s{\sputs\spr:[info\sframe\s0];\snamespace\seval\s::test\s{puts\sns:[info\sframe\s0]}\s};\stest\r\n\s\spr:type\sproc\sline\s1\scmd\s{info\sframe\s0}\sproc\s::test\slevel\s0\r\n\s\sns:type\s<b\sstyle="color:green">eval</b>\sline\s1\scmd\s{info\sframe\s0}\slevel\s0\r\n</pre></code>\r\n\r\nBut\sstill\sworse,\sthe\sthings\schange\salso\sin\sthis\scase\sif\ssomething\selse\sis\sinvolved\saround\s`info\sframe`\sadditionally.<br/>\r\nSo\sadding\sa\s`dict\sget\s...\stype`\saround\sconfuses\sit\sagain:\r\n<code><pre\sstyle="padding-left:10">\r\n%\sproc\stest\s{}\s{\sputs\spr:[dict\sget\s[info\sframe\s0]\stype];\snamespace\seval\s::test\s{puts\sns:[dict\sget\s[info\sframe\s0]\stype]}\s};\stest\r\n\s\spr:proc\r\n\s\sns:<b\sstyle="color:red">proc</b>\r\n</pre></code>\r\nAs\swell\sas\sjust\susage\sof\sset,\sso\sset\sto\svariable\s(despite\sit\sis\scompiled\sin\sNS)\scauses\scompletely\swrong\stype\srecognition:\r\n<pre\sstyle="padding-left:10">\r\n%\sproc\stest\s{}\s{\snamespace\seval\s::test\s{puts\sns:[info\sframe\s0]}\s};\stest\r\n\s\sns:type\s<b\sstyle="color:green">eval</b>\sline\s1\scmd\s{info\sframe\s0}\slevel\s0\r\n%\sproc\stest\s{}\s{\snamespace\seval\s::test\s{puts\sns:[set\sf\s[info\sframe\s0]]}\s};\stest\r\n\s\sns:type\s<b\sstyle="color:red">proc</b>\sline\s1\scmd\s{info\sframe\s0}\slevel\s0\r\n</pre>\r\n\r\nSo\sit\slooks\slike\s`info\sframe`\sis\stotally\sunusable\sat\sthe\smoment\s(or\sat\sleast\spointing\sat\sthe\swrong\sframe,\sif\sone\swants\sto\sretrieve\sthe\stype\sof\sthe\sscope).
J foundin all
J is_private 0
J login sebres
J priority 5\sMedium
J resolution None
J severity Severe
J status Open
J submitter sebres
J subsystem 16.\sCommands\sA-H
J title info\sframe\sdoes\snot\scorrect\srecognize\scurrent\stype\sof\sexecution\sscope
J type Bug
K 2d2a32124406e8494a9d73cf2b668dcddc75fdf6
U sebres
Z c76c5e236f05012e262c91ba81bf0e15