[stringtemplate-interest] it, i, i0 for ST v4
Terence Parr
parrt at cs.usfca.edu
Tue Dec 21 21:07:12 PST 2010
oh, in your case you'd want:
format(x, tag) ::= "..."
Ter
On Dec 21, 2010, at 8:57 PM, Terence Parr wrote:
>
> On Dec 21, 2010, at 8:22 PM, Sam Harwell wrote:
>> This whole issue is an edge case of a larger "problem" I'm facing - I wish
>> that templates with one unassigned argument could be used any place a
>> template with a single arg can be used. From your bold(x) example, what I
>> mean is this:
>>
>> format(tag,x) ::= "<$tag$>$x$</$tag$>"
>>
>> <names:format(tag="b")>
>>
>> The anonymous template version this is exactly what you suggested, with
>> exactly 1 named but unassigned parameter and 0 or more named assignments.
>
> That is exactly how v4 works :) First arg(s) get values. 'cept no names:
>
> <names:format("b")>
>
> T
> _______________________________________________
> stringtemplate-interest mailing list
> stringtemplate-interest at antlr.org
> http://www.antlr.org/mailman/listinfo/stringtemplate-interest
More information about the stringtemplate-interest
mailing list