From: Richard E Maine <[log in to unmask]>
Date: Wednesday, 19 October 2005 0:52
>On Oct 17, 2005, at 5:26 PM, robin wrote:
>
>> From: Richard E Maine <[log in to unmask]>
>>> The repeat factor is one cause of some of the oddities in DATA
>>> statement syntax. Consider something like
>>>
>>> 6*7
>>>
>>> In any context other than a DATA statement, that means 6 times 7....
>...
>> (6)7
>> might work well as a repeat factor that avoids the use of *.
>
>True. But that would be a new syntax
Naturally. That avoids the use of *.
That's why I suggested it.
> - not just an application of the existing one.
The existing one, namely *, is useless in this context, as has already
been pointed out.
> The OP asked why the existing syntax didn't apply. Of
>course, one might extend that question to ask why a new syntax isn't
>developed as a substitute.
>
>My personal position is that the DATA statement already has too much
>special syntax.
That's completely irrelevant. The OP isn't trying to use a DATA statement.
He is using an array constructor.
> I'd not be inclined to favor adding more.
No-one's asking for more in the DATA statement.
> And I don't
>see enough gain to be had from adding a new special syntax for repeat
>factors in array constructors.
You have to agree that (0.0, i = 1, 3) is ham-fisted, n'est-ce pas?
> The functionality is, after all
>available in more verbose form with implied DO, so the only gain is a
>bit of shortening.
It's clarity.
>--
>Richard
|