template function. test array parameter length

ref2401 refactor24 at gmail.com
Sat Jan 5 13:50:17 PST 2013


I have a template function that must work with an array of float 
values.
something like this:

void foo(T : A[], A)(auto ref T arg)
if(is(A == float))
{
	...
}

Array may be static or dynamic. But the length of the array must 
be 16 or 32. How can i test length value?


More information about the Digitalmars-d-learn mailing list