[stringtemplate-interest] Re: [antlr-dev] length of bitset
available?
Terence Parr
parrt at cs.usfca.edu
Sat Jan 21 13:32:52 PST 2006
Cool. Is this something you need right away? i'm overwhelmed with
courses starting up again at the moment.
Ter
On Jan 21, 2006, at 1:11 PM, Kay Roepke wrote:
>
> On 21. Jan 2006, at 22:01 Uhr, Terence Parr wrote:
>
>> None that I could think of. It then begs the question: what if I
>> need number of bytes not words? YOu'll want to be able to
>> multiply by 4. This is fine as long as it's a function of a
>> length versus attribute property. BUT, it opens up the syntax to
>> general arith. expr and I then need to do analysis to figure out
>> if you are doing salary*4.
>
> That's really a question of the semantics of the program one
> generates, is it not? I wouldn't expect ST to do that for me.
> I know I'm dealing with words, because that's what ANTLR spews out.
> If I wanted to do bytes, I'd had to convert that myself. If ANTLR
> would ever change to do bytes, my code
> would break nonetheless. Nice, because then there's no
> justification to do arithmetics in ST, anyway ;)
>
>>> As long as there's no way of doing computations,
>>> it might shouldn't do any harm and be useful, too, for, say, page
>>> flippers on web pages or so.
>>
>> Yup...i intend to add to 2.3; is it a function like <length(names)
>> > like first(), rest()? Seems like. I don't think <names.length>
>> is right nor <names:length()>.
>
> You're right, of course it should be consistent across the board. I
> thing too much in terms of objects and methods nowadays...:)
>
> -k
More information about the stringtemplate-interest
mailing list