Skip to content
Tcl Source Code Ticket Change Details
Login

Ticket Change Details

Overview

Artifact ID: 6df2c70670d154c66d7c5f301342511ea4f60fdb
Ticket: 2251175fffffffffffffffffffffffffffffffff
Expand ({*}), constants, and list syntax
User & Date: ferrieux on 2008-11-12 05:04:10
Changes

  1. icomment:
    I have not checked, but I found this in tclParse.c's history
    
    revision 1.53
    date: 2007/05/30 18:12:59;  author: dgp;  state: Exp;  lines: +138 -53
            * generic/tclBasic.c:   Removed code that dealt with
            * generic/tclCompile.c: TCL_TOKEN_EXPAND_WORD tokens representing
            * generic/tclCompile.h: expanded literal words.  These sections were
            mostly in place to enable [info frame] to discover line information
            in expanded literals.  Since the parser now generates a token for
            each post-expansion word referring to the right location in the
            original script string, [info frame] gets all the data it needs.
    
            * generic/tclInt.h:     Revised the parser so that it never produces
            * generic/tclParse.c:   TCL_TOKEN_EXPAND_WORD tokens when parsing an
            * tests/parse.test:     expanded literal word; that is, something like
            {*}{x y z}.  Instead, generate the series of TCL_TOKEN_SIMPLE_WORD
            tokens to represent the words that expansion of the literal string
            produces.  [RFE 1725186]
    
    So, it looks like prior to this date, things were going as per what I called "Solution (2)". Since that implies runtime expansion, which involves Tcl_GetListFromObj, I'd risk a guess that the bug appeared at that time :-{
    
    So the dilemma becomes:
    
       (1) complexify Tcl_Token handling a bit to flag must-collapse-backslash tokens, to be collapsed by the client.
    
       (2) go back to situation as of revision 1.53 of tclParse.c and bury [RFE 1725186]
    
    What do you think ?
    
    
    
    
  2. login: "ferrieux"
  3. mimetype: "text/plain"
  4. username: "ferrieux"