Skip to content
Tcl Source Code History Of Ticket 1357401
Login

History Of Ticket 1357401

Artifacts Associated With Ticket 1357401

  1. Ticket change [dae6291141] (rid 107867) by nobody on 2005-11-15 14:11:20:

    1. assignee initialized to: "nobody"
    2. cmimetype initialized to: "text/plain"
    3. comment initialized to:
      The following two simple DString macros would be
      useful both in the Tcl core itself and for the general
      Tcl extension writer.
      
      
      #define Tcl_DStringClear(dsPtr) \
        ((dsPtr)->string[((dsPtr)->length = 0)] = '\0')
      
      #define Tcl_DStringAppendDString(dsPtr,ds2Ptr) \
        Tcl_DStringAppend((dsPtr), \
          Tcl_DStringValue(ds2Ptr), \
          Tcl_DStringLength(ds2Ptr) \
        )
      
      
      
      The first, Tcl_DStringClear, simply clears an already 
      Init'd DString's buffer.
      
      For cases where this is useful (to reuse a DString), the 
      core currently either does a Tcl_DStringFree() or
      a Tcl_DStringSetLength(...,0) neither of which is ideal.
      In particular using Tcl_DStringFree might free a malloc'd
      buffer which might have to be re-malloced. 
      The new macro would also help documenting the
      code's intention.
      
      The second is simply a wrapper around 
      Tcl_DStringAppend which simplifies and self documents
      the code so that it is obvious that what is being
      appended is a Tcl_DString.
      
      
    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: "nobody"
    9. subsystem initialized to: "None"
    10. title initialized to:
      Add Tcl_DStringClear & Tcl_DStringAppendDString to tcl.h
      
    11. type initialized to: "RFE"
  2. Ticket change [264654335d] (rid 88312) by dkf on 2005-11-15 22:21:16:

    1. assignee changed to: "msofer"
    2. subsystem changed to: "10. Objects"
  3. Ticket change [8898f23b3c] (rid 131894) by dkf on 2012-07-03 15:33:25:

    1. assignee changed to: "dkf"
    2. icomment:
      I'd be inclined to put them in tclInt.h to start out with. Also, TclDStringAppendObj would be reasonable and we already have TclDStringResult.
      
      These sorts of things would be long-term suitable for promoting to the public API (though probably always as functions; macros are too likely to have surprising side-effects).
      
      
    3. login: "dkf"
    4. mimetype: "text/plain"
    5. username: "dkf"
  4. Ticket change [d44f651696] (rid 123421) by dkf on 2012-07-03 21:54:18:

    1. icomment:
      There are now Tcl-internal implementations of these in 8.6; keeping this FRQ open as they're candidates for future exposure.
      
      
    2. login: "dkf"
    3. mimetype: "text/plain"
    4. username: "dkf"
  5. Ticket change [74af33fa78] (rid 105249) by nijtmans on 2012-07-04 19:47:36:

    1. icomment:
      Win32 build broken now:
      
      tclWinReg.o:tclWinReg.c:(.text+0x12e5): undefined reference to `_TclDStringAppendObj'
      
      Recommended to revert your changes in tclWinReg.c.
      
      
    2. login: "nijtmans"
    3. mimetype: "text/plain"
    4. priority changed to: "9 Immediate"
    5. username: "nijtmans"
  6. Ticket change [fbd7a8437f] (rid 108131) by dkf on 2012-07-04 20:41:31:

    1. icomment:
      oops; fixed
      
      
    2. login: "dkf"
    3. mimetype: "text/plain"
    4. username: "dkf"
  7. Ticket change [4d43e865e2] (rid 127027) by nijtmans on 2012-07-04 22:14:22:

    1. priority changed to: "5 Medium"
  8. Ticket change [7e301fac37] (rid 97361) by nijtmans on 2012-07-04 22:14:38:

    1. icomment:
      Fix confirmed
      
      
    2. login: "nijtmans"
    3. mimetype: "text/plain"
    4. username: "nijtmans"