Overview
| Artifact ID: | 26cc6aa69840c15e76ce05ee6d5607dde0df1e99 |
|---|---|
| Ticket: | 550799ffffffffffffffffffffffffffffffffff
Evaluation of substitutions in [regsub] |
| User & Date: | dkf on 2002-04-30 21:47:10 |
Changes
- assignee changed to: "nobody"
- cmimetype changed to: "text/plain"
- comment changed to:
It would be nice if there was a switch to [regsub] to make it automatically pass the strings it is substituting through, say, Tcl_SubstObj() before substitution. At the moment you need to perform several stages of substitution, first hiding all significant characters in the input string, then substituting things (usually looking like command substitutions) which describe what you actually want to change, and finally passing the result through [subst] to convert the substitutions into their actual value. Sure this works, but it is not a technique that is clear to anyone other than a Tcl guru, and being able to perform the substitution on strings as they are being replaced by [regsub] would be much clearer (especially as it would also allow the removal of the pre-filtering stage as well.) Naturally, if this was done some care would need to be taken with ensuring that those parts derived from the string being matched were properly quoted as well, but this idea already exists in principle in Tk (in binding script substitutions) so it won't be foreign to users...
- foundin changed to: "None"
- priority changed to: "5 Medium"
- resolution changed to: "None"
- status changed to: "Open"
- submitter changed to: "dkf"
- subsystem changed to: "43. Regexp"
- title changed to: "Evaluation of substitutions in [regsub]"
- type changed to: "RFE"