With all of those minor changes, are you sure that this really helps? c++ compilers can optimise those things quite efficiently.
Another point I am scared by is that things stop working - some of the methods are not explicitly unit-tested. Feel free to add such tests, although I know its lots of work and we have tests for final results (which all passed your patch)