Actually, you are right: copying `std::string` can be quite cheap (if it is implemented using copy-on-write semantics). See http://stackoverflow.com/questions/1466073/how-is-stdstring-implemented. But I wouldn't rely on that as the standard doesn't guarantee this.