Bracket notation for collections (original) (raw)
Mark Thornton mthornton at optrak.co.uk
Wed Mar 25 13:53:52 PDT 2009
- Previous message: PROPOSAL: Binary Literals
- Next message: PROPOSAL: Return 'this'
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
I notice that Joe Darcy has this on his todo list. I wonder if it might stretch to something like this:
interface Matrix2d { @arrayGet double get(int i, int j); @arraySet void set(int i, int j, double value); }
//
Matrix2d m; double z = m[1,2];
m[2,4] = 2*z;
Would the use of annotations for such a purpose be permitted?
Regards, Mark Thornton
- Previous message: PROPOSAL: Binary Literals
- Next message: PROPOSAL: Return 'this'
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]