Sane and Safe C++ Class Types
Explore a comprehensive lecture on creating safe and sane C++ class types in this C++Now 2019 conference talk. Delve into the evolution of C++ special member functions, from the "Rule of Three" to the "Rule of Five/Six" and "Rule of Zero". Examine Howard Hinnant's table on language rules for special members and learn a consistent approach to defining and declaring special members for different class types. Discover surprising suggestions aimed at reducing code clutter and improving software quality. Cover topics such as typical problems in C, use after free, regular types, builtin types, default constructible classes, type traits, empty base class optimization, unique pointer types, and inherited constructors. Gain insights from Peter Sommerlad, Professor at IFS Institute for Software, on creating more efficient and safer C++ code.