Effective Modern C++ by Scott Meyers

bkt_effective_cpp

Summary: Solid introduction to modern C++

On a day to day basis I work with C++ legacy code. No surprises, just classes and some overloaded operators. Nothing special. I have jumped into Effective Modern C++ as I wanted to know what’s really behind C++11 and C++14. And there’s a lot.

I bet, after reading this book, you will immediately try to drop all your NULLs in favor of nullptr (have you ever tried to overload function that has either pointer or int as argument). I bet you will strongly consider {} based initialization. Aliases and scoped enums are also nice to have features of the langue. And, what really caught me by surprise were auto variables. I am in favor of strong typing, but after reading explanation of autos and how can you benefit from them in context of templates, I think I will change my mind.

The same thing refers to pointers. I am an old school, C based developer, and I always use regular, old style pointers. But I am pretty sure I will take a closer look at std based ones.

Book explains topics in consistent, but demanding way. This is not a C++ primer or cook book style title. It will not give you straight answers related to your code and problems that you might be facing. Instead, it will give you systematic, and pragmatic overview of new features in C++11/C++14. There are lots of references to C++98 that give you explanation for why should you consider moving forward.

If you are new to C++, wait a little bit before reading this one. Take a closer look at Professional C++ by Marc Gregoire instead. Then, get back to this one.

Anyway, if you work with C++ legacy code and you want to get familiar with new stuff that is already out there, I really recommend this one.

O’Reilly (print): Effective Modern C++
Safari Books Online: Effective Modern C++