How to get the element type of an array?

Basile B. b2.temp at gmx.com
Tue Aug 25 05:02:46 UTC 2020


On Tuesday, 25 August 2020 at 03:41:06 UTC, Jon Degenhardt wrote:
> What's the best way to get the element type of an array at 
> compile time?
>
> Something like std.range.ElementType except that works on any 
> array type. There is std.traits.ForeachType, but it wasn't 
> clear if that was the right thing.
>
> --Jon

I'm curious to know what are the array types that were not 
accepted by ElementType ( or ElementEncodingType ) ?


More information about the Digitalmars-d-learn mailing list