simple template constraint - compile error.

Adam D. Ruppe via Digitalmars-d-learn digitalmars-d-learn at puremagic.com
Sun Jun 7 21:06:41 PDT 2015


On Monday, 8 June 2015 at 04:02:26 UTC, WhatMeWorry wrote:
> Why would a working function call stop working just because a 
> constraint was added to the function?

because T is float... which isn't a dynamic array, so the 
constraint doesn't match. Just remove the [] after T[] in your 
signature and you should be ok.


More information about the Digitalmars-d-learn mailing list