Using bind1st for a method that takes argument by reference

std::bind1st and std::bind2nd don’t accept functors which take reference arguments, because they themselves form references to these arguments. You can

  1. use pointers for your function inputs instead of references
  2. use boost::bind
  3. accept the performance cost of copying the string

Leave a Comment