[Date Prev][Date Next][Thread Prev][Thread Next]
[Date Index]
[Thread Index]
- Subject: Re: A Question of Notation
- From: Geoff Leyland <geoff_leyland@...>
- Date: Sun, 19 Dec 2010 22:02:30 +1300
On 19/12/2010, at 9:20 PM, steve donovan wrote:
> I'm particularly struck by the fact that ls[R(1,3)] and ls[Range(1,3)]
> happen to be equivalent, but only on the right-hand side of an
> assignment.
I'm guessing that Range(1,3) returns a "vanilla" table, and that R(1,3) returns some other object (a table, of course, but with a metatable). When would you want to use a real table where you couldn't use the object returned by R? I guess I'm asking why you need Range at all?
(Rima does things like a[{i=I}] = i^2, which strikes me as similar, but not what you're looking for)
Cheers,
Geoff