Type of Array.length?

Daniel Keep daniel.keep+lists at gmail.com
Sat Jan 20 03:12:22 PST 2007


Heinz wrote:
> Hi,
> 
> I just want to know what type is the one returned by the .length property of an array.
> 
> Thanks.

When in doubt, find out!

import std.stdio;

void main()
{
     char[] foo;
     writefln("typeof(array.length) == %s", typeid(typeof(foo.length)));
}


More information about the Digitalmars-d-learn mailing list