Extension Method?

oldrev wstring at gmail.com
Wed Mar 21 02:48:35 PDT 2007


Hi all:

Recently, I have found a undocumented(?) feture that a individual function with one parameter of array can be used as a method:

int getLength(int[] arr) { return arr.length; }
int[] foo = [1, 2, 3];
int len = foo.getLength();

Where I can find the information for this?

Thanks a lot!.

regards.



More information about the Digitalmars-d-learn mailing list