Variadic template templates and perfect forwarding
This question on the object generator pattern got me thinking about ways to automate it. Essentially, I want to automate the creation of functions like std::make_pair , std::bind1st and std::mem_fun so that instead of having to write a different function for each template class type, you could write a single variadic template template function that handles all cases at once. Usage of this function would be like: make<std::pair>(1, 2); // equivalent to std::make_pair(1, 2) make<std::binder2nd>(&foo, 3); // equivalent to std::bind2nd(&foo, 3); Is it possible to write this function make ? I have