On 7 June 2015 at 11:33, Ville Voutilainen <ville.voutilai...@gmail.com> wrote: >>> You use a lot: typename enable_if<X, bool>::type=true >>> while the current code seems to favor: class=typename enable_if<X>::type. >>> I don't really care which one is used, but it is easier to read when the >>> style is consistent through the library. >> It's not a style issue. That template parameter needs to be a non-type one, >> otherwise the overloads are ambiguous. > ...and I think it doesn't necessarily need to be non-type, I think it can be > made to work with a type parameter that is enable_if<X, true_type> > and enable_if<X, false_type> for the mutually-exclusive overloads.
Except that no, it can't. It really needs to be a non-type parameter. :P