Artifacts Associated With Ticket 582522ffffffffffffffffffffffffffffffffff
Ticket change [5085a70c8a] (rid 125987) by dgp on 2002-07-16 22:07:25:
- assignee initialized to: "msofer"
- cmimetype initialized to: "text/plain"
- comment initialized to:
% proc print args {puts "printtrace $args"} % proc foo {} {puts orig_foo} % interp alias {} al_foo {} foo al_foo % trace add execution foo enter {print foo} % trace add execution al_foo enter {print al_foo} % foo printtrace foo foo enter orig_foo % al_foo printtrace al_foo al_foo enter orig_foo % The [print foo] trace is missing. It should have been fired by [al_foo]. The problem seems to be that execution traces are performed by TclEvalObjvInternal() and aliases get evaluated by TclObjInvoke() which bypasses that and executes the command procedure directly. In combination with Bug 582506, it seems the correct solution may be to tie execution traces into the command procedure itself instead of in TclEvalObjvInternal(). - foundin initialized to: "obsolete: 8.4b2"
- priority initialized to: "5 Medium"
- resolution initialized to: "None"
- status initialized to: "Open"
- submitter initialized to: "dgp"
- subsystem initialized to: "45. Parsing and Eval"
- title initialized to: "aliases do not fire exec traces"
- type initialized to: "Bug"
Ticket change [076f027834] (rid 89396) by msofer on 2002-07-29 07:17:28:
- icomment:
Logged In: YES user_id=148712 Fixed by sending aliases through TEOI. Leaving openas reminder to check into the other suggestion. An alternative would be to eliminate the independent import mechanism, and just use it as a front-end for aliases which are now almost as fast.
- login: "msofer"
- mimetype: "text/plain"
- priority changed to: "3 Low"
- resolution changed to: "Fixed"
- username: "msofer"
- icomment:
Ticket change [2535fb776a] (rid 88131) by dgp on 2002-07-29 12:03:18:
- icomment:
Logged In: YES user_id=80530 I haven't reviewed the fix, but be sure to check it carefully that it preserves the same semantics. The difference between "invoke" and "eval" is very important, especially to be sure that aliases in safe interps don't "leak safety".
- login: "dgp"
- mimetype: "text/plain"
- username: "dgp"
- icomment:
Ticket change [0a92fd7bc8] (rid 113846) by msofer on 2002-07-29 20:53:14:
- icomment:
Logged In: YES user_id=148712 I'm pretty sure safety has been maintained: I only modified AliasObjCmd which processes aliases and never sent the flag TCL_INVOKE_HIDDEN to TclObjInvoke. TEOVI looks for commands using Tcl_GetCommandFromObj(), so essentially using a cached value if (available && valid), and looking up by name otherwise. So the issue is: could the cmdName object have a cached reference to a hidden command? I'll build extra safety and make the Alias structure keep a private copy of the targetCmdName object, so that it never keeps a foreign cached value. BTW, traces on hidden commands are still not being fired ...
- login: "msofer"
- mimetype: "text/plain"
- username: "msofer"
- icomment:
Ticket change [10fbfd4016] (rid 95066) by msofer on 2002-07-29 22:54:47:
- icomment:
Logged In: YES user_id=148712 OK: if a command is hidden, Tcl_GetCommandFromObj() will invalidate any cached reference. It works OK: [mig@mini unix]$ ./tclsh % proc a {} {puts hello} % interp alias {} b {} a b % b hello % interp hide {} a % b ambiguous command name "a": after append array auto_execok auto_import auto_load auto_load_index auto_qualify Adding this to the testsuite (interp-9.3) - login: "msofer"
- mimetype: "text/plain"
- username: "msofer"
- icomment:
Ticket change [14cb716d8d] (rid 124463) by dgp on 2002-08-01 02:45:16:
- icomment:
Logged In: YES user_id=80530 interesting. I was actually more concerned about the arguments, making sure that the right ones gets substituted in the right interp.
- login: "dgp"
- mimetype: "text/plain"
- username: "dgp"
- icomment:
Ticket change [3e4312a763] (rid 121232) by dkf on 2003-06-26 17:30:34:
- subsystem changed to: "46. Traces"
Ticket change [942c3fc3ef] (rid 105940) by dgp on 2003-06-26 22:47:03:
- assignee changed to: "dgp"
Ticket change [cd2f776fd4] (rid 95844) by dgp on 2004-07-13 21:26:44:
- assignee changed to: "msofer"
- icomment:
Logged In: YES user_id=80530 Anything left to resolve here, or can we close this?
- login: "dgp"
- mimetype: "text/plain"
- username: "dgp"
Ticket change [d74d9c0bf9] (rid 123958) by msofer on 2004-07-13 22:02:28:
- closedate changed to: "2004-07-13T15:02:28"
- closer changed to: "msofer"
- status changed to: "Closed"