When I supply both types to the template arguments (std::string,std::string) in this case, everything is fine. I would have thought that the compiler might be able to infer that StringMap = std::string,std::string but it looks like I'm wrong.

Is this mainly because the compiler cannot mismatch on number of type arguments supplied in a template?

When I supply both types to the template arguments (std::string,std::string) in this case, everything is fine. I would have thought that the compiler might be able to infer that StringMap = std::string,std::string but it looks like I'm wrong.

Is this mainly because the compiler cannot mismatch on number of type arguments supplied in a template?