On Friday, 29 January 2016 at 23:44:56 UTC, Basile B. wrote:
Haven't you seen my answer about constraint ?

If you put a constraint on your function template then invalid instantiations are rejected. I mean... this language feature is not just ornamental...

What do you think constraints are used for otherwise ^^

Yes, I've seen it, thanks.
Requiring the user to write the constraint might indeed enforce a better style, but I want to be able to test it even if the user forgets the constraint. Otherwise she'll get cryptic error messages from some other code assuming that CallsFoo!NoFoo is a valid type.

Reply via email to