CPPCON2020 Session Review: The Hidden Secrets of Move Semantics

I “virtually” attended this session and followed it fully, and went through it again to write this short session review. But then, I’m biased. I have been reading C++ Move Semantics – The Complete Guide, since Nico started publishing the first chapters, and recently posted a minor review for the book. Furthermore, I translated his best-seller, C++17 – The Complete Guide, to Spanish.

Therefore, I was very familiar with the material, and yet, enjoyed the session very much. A cursory review of move semantics–or better, get a copy of his book–will let you derive the most value from this session.

Nico picks up a simple class template where all you want to do is insert elements. Sure. Then he starts peeling away the different ways in which move semantics comes into the picture, what to use, what to avoid, and a number of do’s and don’ts at the end of the session. If you want to learn what the term temploid means, check this out. If you want to overload by a reference qualifier, check this out.

Still controversial for some is the use of universal reference, which I guess is one of those terms that we’ll get stuck with and generate polemic conversations when compared with forwarding reference. Consider the translation of email in some languages (courrier électronique, courriel, correo electrónico). Nah, simply say email. Same here. Unless you want to pick up another polemic term.

You can check forwarding references in cppreference or in Spanish in es.cppreference.

By publishing professional C++ books, Nico is an educator, and do we need more of those. So, if you’re wondering if it will be time well spent should you choose to watch it? You bet.

This entry was posted in C++, C++17, C++20 and tagged , , , , , . Bookmark the permalink.

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s