Skip to content
Tcl Source Code Ticket Change Details
Login

Ticket Change Details

Overview

Artifact ID: 776b12fa4d83f285d56a58402ed868901cfcbee2
Ticket: 219241ffffffffffffffffffffffffffffffffff
add [trace command] command
User & Date: nobody on 2000-10-26 05:04:04
Changes

  1. assignee changed to: "nobody"
  2. cmimetype changed to: "text/plain"
  3. comment changed to:
    OriginalBugID: 5048 RFE
    Version: 8.3
    SubmitDate: '2000-04-12'
    LastModified: '2000-08-24'
    Severity: LOW
    Status: Assigned
    Submitter: ericm
    ChangedBy: ericm
    RelatedBugIDs: 5967
    OS: All
    FixedDate: '2000-10-25'
    FixedInVersion: 8.4a2
    ClosedDate: '2000-10-25'
    
    
    It would be great to be able to trace commands the same way we do variables.
    For example, we could do command call counts with this:
    
    trace command myCommand execute myHandler
    proc myHandler {args} {
    ...
    }
    
    This should also allow us to trace creation and deletion of commands:
    
    trace command myCommand create ...
    trace command myCommand delete ...
    
    The second of these in particular is important for megawidget support.  Consider the typical megawidget setup, which creates a frame .f, then renames the frame proc to .f:real, so that it can alias the .f command to the megawidget widget proc.  Now if the user does [rename .f {}], this does not really clean up the megawidget (unlike a true widget, where renaming the widget command deletes the widget).  If we could trace the deletion, however, we could properly clean up in this case.
    
    - eric
    
    
    
    With the patch from Vince Darley (bug: 5967), we can trace rename and delete for commands.  Execution and creation are still pending; of these, creation seems unlikely to happen, as it doesn't really seem useful.
    
    The particular implemention of trace command execution is still undetermined.
    
       Eric Melski                            The Other Tcl Guy
       ericm at ajubasolutions.com            Ajuba Solutions
    
    -- 08/24/2000 ericm
    
    
    
  4. foundin changed to: "obsolete: 8.3"
  5. priority changed to: "5 Medium"
  6. resolution changed to: "None"
  7. status changed to: "Open"
  8. submitter changed to: "nobody"
  9. subsystem changed to: "81. Bundled Packages"
  10. title changed to: "add [trace command] command"
  11. type changed to: "RFE"