'''Background''' TIP #144 ''Argument Expansion Syntax'' [http://www.tcl.tk/cgi-bin/tct/tip/144.html] (and the earlier TIP #103 ''Argument Expansion Command'' [http://www.tcl.tk/cgi-bin/tct/tip/103.html]) proposes to add syntax to Tcl to perform argument expansion in a safe and efficient manner. For example, instead of having to write: eval [linsert $args 0 exec $program] The TIP would allow one to say: exec $program {}$args where the leading '''{}''' indicates that the remainder of the word shall be parsed as a list (after applying the usual substitution rules), and each element of the list is passed as a separate argument to the command. Naturally, there has been a great deal of discussion about what syntax should be used to indicate argument expansion. The two most popular options seem to be {} and ` (backquote). The main advantage of the {} syntax is that it can be added to Tcl 8.5 without breaking backwards-compatibility, as such usage is currently a syntax error. Any other option would have to wait until Tcl 9.0. A similar poll was conducted on the tcl-core mailing list. The result is on the [Argument Expansion Poll Summary] page. '''Poll''' The purpose of this poll is to get a feel for the Tcl community's preferences regarding the proposed syntaxes. The poll is in two parts: the first asks which syntax would be preferable ''if backwards compatibility were not an issue''. The second asks if the backwards-compatible syntax would be acceptable if it meant the feature could be introduced earlier. Please vote by signing your name or initials after the proposed option. Discussion moved to [DISCUSSION: Argument Expansion Syntax] '''Part 1: which syntax do you prefer?''' ''Option 1: leading {}'': [Vince], [RS], [Roy Terry], [Jeffrey Hobbs], [EB] ''Option 2: leading `'': [Joe English], [Jacob Levy], [David Welton], [ramsan], [lv], [SO], [US] ''Option 3: other (please specify)'': * ''leading {expand}'' [DGP], [Daniel Steffen], [MS], [KBK], [Peter Spjuth], [de], [Donald Arseneau] * ''leading @'': [Larry Smith] * ''$()'': [Larry Smith], [Steve Redler IV] ''([EB]: This syntax can't be used, this is an empty array name dereference, used in [stooop], for example)'' * ''[[expand ]]'' If someone can do it: [Steve Redler IV], [MAK] * ''^^$foo and ^^[[foo]]'' : [Setok] * Added functionality to Tcl that allows "macro" commands: commands can edit the calling command line. Dangerous in a semi-Tclish fashion. F.ex. file join [[expand $MyList]] : [Setok] ''Option 4: neither'': marc, THIRION ''Option 5: anything, just give me the functionality'': [KPV], [ulis] '''Part 2: Is {} acceptable for Tcl 8.5?''' ''Yes, {} is acceptable'': [DGP], [Vince], [Daniel Steffen], [RS], [KBK], [Peter Spjuth], [Roy Terry], [EB] ''Yes, ` is acceptable (never mind the slight chance of breakage)'': [lv], [US] ''Yes, $() is acceptable'': [Larry Smith], [Steve Redler IV] ''Yes, anything is acceptable'': [KPV], [ulis] ''No, wait until Tcl 9 to add the feature'': [Joe English], [Jacob Levy], marc, THIRION, [SO], [Setok] ''No, we do not need this functionality'': ---