Adrian Bentley <adruab@xxxxxxxxx> writes: > Ok so here's my problem, I have this templatized class (with T). And > for it I'm defining a templatized member function (with F), I want the > function to take a comparison operation as a member to make it more > flexible. > > I'm defining: > > template < typename T > > class myclass > { > public: > template < typename F > > bool valid(const F & func = std::less<T>()) const [snip] 14.8.2.4/17: # A template type-parameter cannot be deduced from the type of a # function default argument. It then continues with an example much like yours.