September 2016

In the previous post I have compared two alternative ways of transforming a string to upper case, both using std::transform: one that modifies an existing string and one that generates a new one by inserting at the end using std::back_inserter. For the second alternative I have presented two implementations, one that does an initial reservation…

Read More A comparison of two std::transform alternatives revisited

UPDATE: For an update on the implementation and the conclusions see A comparison of two std::transform alternatives revisited. I was writing a small utility function to transform a string to uppercase. The obvious solution for that is std::transform, but as I was writing it I realized there are several alternatives: transform an existing string, by…

Read More A comparison of two std::transform alternatives