Skip to content
Tcl Source Code History Of Ticket 403430ffffffffffffffffffffffffffffffffff
Login

History Of Ticket 403430ffffffffffffffffffffffffffffffffff

Artifacts Associated With Ticket 403430ffffffffffffffffffffffffffffffffff

  1. Ticket change [417b2e7afc] (rid 116198) by daknol on 2001-01-26 00:18:44:

    1. assignee initialized to: "nobody"
    2. cmimetype initialized to: "text/plain"
    3. comment initialized to:
      
      this is a patch for which i didn't see any related PR, so i'm not entirely certain if this patch will be a popular one or not...
      
      as mentioned in patch#103420, my company's tools typically register a callback with Tcl_CreateTrace() so that we can automatically generate a command  "history log" or "replay script" of a tool's usage.  one of the problems we've had with the tcl trace involves the 'level' argument that gets passed to our trace callback function.  specifically, bracketed commands whose results are passed as arguments to another command is the issue.  
      
      consider two tcl commands, 'a' and 'b', where the results of 'b' are commonly passed as an argument to 'a'.  ie, "a [ b ]".  with today's implementation, a tcl trace callback will be invoked twice, once with the 'command' argument equal to "b", and then again with 'command' equal to "a [ b ]".  the 'level' argument in both invocations is the *same* value, which presents a problem for me.  if the 'level' provided in the first invocation was 'X', i would expect the second invocation to be 'X-1'.  otherwise, i have no way of telling that the first invocation is merely being evaluated as another command's argument.
      
      since the bracketed command cannot be distinguished from a regular command, our resulting command log is faulty in that it will first print 'b' and then print 'a [ b ]'.  
      
      the fix for this involves wrapping an increment/decrement of iPtr->numLevels before/after a call to a bracketed command.  i'm not convinced the patch i've provided below is the absolute cleanest or best way to achieve our goal, but it seems to work just fine for us.
      
      it'd be nice to see this patch encorporated into a future release of tcl, but i also realize there may be some argument to the contrary that i haven't seen yet...
      
      
    4. foundin initialized to: "None"
    5. priority initialized to: "5 Medium"
    6. resolution initialized to: "None"
    7. status initialized to: "Open"
    8. submitter initialized to: "daknol"
    9. subsystem initialized to: ""
    10. title initialized to:
      Tcl_CreateTrace() callback - a proposed 'enhancement'
      
    11. type initialized to: "Patch"
  2. Add attachment "None" [56456b8da3] (rid 94289) by daknol on 2001-01-26 07:18:44.

  3. Ticket change [93511ec2f8] (rid 105792) by dkf on 2001-01-26 17:21:10:

    1. icomment:
      This might break other code - we ought to consult with the rest of the community on this...
      
      
    2. login: "dkf"
    3. mimetype: "text/plain"
    4. username: "dkf"
  4. Ticket change [acf9660307] (rid 101387) by dgp on 2001-02-22 07:06:13:

    1. subsystem changed to: "45. Parsing and Eval"
  5. Ticket change [13b8cb3814] (rid 124268) by msofer on 2001-05-22 05:38:38:

    1. assignee changed to: "msofer"
    2. icomment:
      Logged In: YES 
      user_id=148712
      
      Related to: bug #219362, patch #403420
      
      
    3. login: "msofer"
    4. mimetype: "text/plain"
    5. username: "msofer"
  6. Ticket change [a725f29392] (rid 98733) by msofer on 2001-12-07 03:16:50:

    1. closedate changed to: "2001-12-06T20:16:50"
    2. closer changed to: "msofer"
    3. icomment:
      Logged In: YES 
      user_id=148712
      
      This doesn't fit with tcl's way of seeing things: it is NOT
      a who is calling b in the example.
      
      The way it works and is documented is: b's result as an
      argument to a. The level count is correct, the log's output
      corresponds to the real evaluation order.
      
      
      
      
    4. login: "msofer"
    5. mimetype: "text/plain"
    6. status changed to: "Pending"
    7. username: "msofer"
  7. Ticket change [30d1c819bf] (rid 93325) by msofer on 2001-12-07 21:01:27:

    1. closedate changed to: "2001-12-07T14:01:27"
    2. closer changed to: "msofer"
    3. resolution changed to: "Rejected"
    4. status changed to: "Closed"