In C++ we can't pass certain functions to algorithms. I suspect it's when they're overload or templates:
vector<string> xs = {"12", "34"};
vector<int> ys = transform_to_vec(xs, stoi); // compile error
The simplest workaround I've found is:
#define PLEASE(F) ([](auto&& x) { return F(forward<decltype(x)>(x)); })
vector<int> ys = transform_to_vec(xs, PLEASE(stoi));
Is there a better way?