Skip to content
Tcl Source Code History Of Ticket 1771726
Login

History Of Ticket 1771726

Artifacts Associated With Ticket 1771726

  1. Ticket change [6b481e0f49] (rid 128298) by deusued on 2007-08-10 14:58:12:

    1. assignee initialized to: "msofer"
    2. cmimetype initialized to: "text/plain"
    3. comment initialized to:
      As a loyal and devout Tcl professional (7+ years), I have come across a situation where I would really -love- to be able to force a variable type, or cast it, as a single type.
      
      While this may incur overhead, I would like to believe that it could be implemented in such a manner that both execution speed would be significantly faster (no casting required if a specific bit is set on the variable) and potentially reducing the memory overhead necessary to cast (I'm out of water here, though).
      
      ex:
      %set -double myDouble 1.002
      %lappend myDouble 2
       /error thrown, much like passing an array in as the first arg/
      %set -string myString "1.01"
      %expr $myString + 2.01
       /error thrown, much like passing {} in/
      
    4. foundin initialized to: "None"
    5. is_private initialized to: "0"
    6. priority initialized to: "5 Medium"
    7. resolution initialized to: "None"
    8. status initialized to: "Open"
    9. submitter initialized to: "deusued"
    10. subsystem initialized to: "07. Variables"
    11. title initialized to: "Forced Variable Types"
    12. type initialized to: "RFE"
  2. Ticket change [4ec35a666a] (rid 125699) by dgp on 2007-08-11 02:22:33:

    1. assignee changed to: "dgp"
    2. closedate changed to: "2007-08-10T19:22:33"
    3. closer changed to: "dgp"
    4. icomment:
      Logged In: YES 
      user_id=80530
      Originator: NO
      
      
      To restrict the set of values
      a variable may hold, use variable
      write traces.
      
      
    5. login: "dgp"
    6. mimetype: "text/plain"
    7. resolution changed to: "Invalid"
    8. status changed to: "Closed"
    9. username: "dgp"
  3. Ticket change [67c9424e4c] (rid 102950) by deusued on 2007-08-11 02:34:47:

    1. icomment:
      Logged In: YES 
      user_id=741274
      Originator: YES
      
      I must not have conveyed my interest well.
      
      I need -not- to restrict what variable types a variable may contain -- I know exactly what type I am using.  I am looking for a significant reduction in memory usage as well as speed reduction (by forcing casting) *without* increasing cost (by way of time).  I am -not- going to be tracing them.  
      
      I am talking about a problem of scale, not a problem of usability.  
      
      
    2. login: "deusued"
    3. mimetype: "text/plain"
    4. status changed to: "Open"
    5. username: "deusued"
  4. Ticket change [849b4edf61] (rid 117581) by dgp on 2007-08-11 02:44:31:

    1. assignee changed to: "msofer"
    2. icomment:
      Logged In: YES 
      user_id=80530
      Originator: NO
      
      
      Are you suggesting a change so radical that
      a Tcl variable would be able to hold a value
      that was not a Tcl_Obj ?  (Trying to make sense
      of phrases like "forcing casting" in this context.
      Tcl does not do "casting".  Its model is to treat
      values as strings).
      
      If scaling issues are the real problem, has miguel's
      recent work on Var Reform (Tcl Path 1750051) helped
      at all?  That patch is reported to cut Tcl variable
      memory usage in half.
      
      If I still don't get it, perhaps a proposed patch is
      the clearest way for you to express to us precisely what
      it is that you want.
      
      
      
    3. login: "dgp"
    4. mimetype: "text/plain"
    5. username: "dgp"
  5. Ticket change [01957463c8] (rid 119504) by msofer on 2007-08-22 22:46:16:

    1. closedate changed to: "2007-08-22T15:46:16"
    2. closer changed to: "msofer"
    3. icomment:
      Logged In: YES 
      user_id=148712
      Originator: NO
      
      There is no way of doing what you want, not in Tcl.
      
      The first example could indeed be done via traces, and it could (in principle) be done within the core. But at a huge cost in complexity, and ... having options to [set]? I do not think this can fly.
      
      The second example is fundamentally impossible: you are asking the variable myString to be able to only hold string values (that cannot be reinterpreted as something else? NOT Tcl at all!). You are also asking the value $myString to KNOW it is held in such a variable. 
      
      I do not have enough info to understand where you see memory or runtime savings with such an approach, should it be feasible at all. Please provide detailed info - or even a patch, as suggest below.
      
      
    4. login: "msofer"
    5. mimetype: "text/plain"
    6. status changed to: "Pending"
    7. username: "msofer"
  6. Ticket change [cc2ee122c3] (rid 95646) by sf-robot on 2007-09-06 09:20:05:

    1. closedate changed to: "2007-09-06T02:20:05"
    2. closer changed to: "sf-robot"
    3. icomment:
      Logged In: YES 
      user_id=1312539
      Originator: NO
      
      This Tracker item was closed automatically by the system. It was
      previously set to a Pending status, and the original submitter
      did not respond within 14 days (the time period specified by
      the administrator of this Tracker).
      
      
    4. login: "sf-robot"
    5. mimetype: "text/plain"
    6. status changed to: "Closed"
    7. username: "sf-robot"