This month we hosted Rich Yonts, the author of a Manning publication title (MEAP/Beta) – 100 C++ Mistakes and How to Avoid Them

The recording can be found in our San Diego C++ Meetup channel:

San Diego C++ Meetup #63

The meetup even link can be found here.

About Rich Yonts:

Rich Yonts is a Senior Software Engineer at Teradata and a long-time software engineer using C++, Java, and Python. Rich held a number of technical and leadership roles during his many years at IBM and Sony. As an assistant professor, he has dealt with questions and issues of undergraduate and graduate students learning programming. He has deep experience on large code bases and considers himself both a student and a teacher of C++.

Rich cherry-picked few examples from the book and presented to the group.

Here is the summary of the topics:

  1. The challenges when dealing with old codebase in various companies. i.e. dealing with 98/03 and not beyond that.
  2. Narrowing values, uniform initialization to detect narrowing.
  3. Referring to an uninitialized data member and UB.
  4. Post vs pre increment of type instances.
  5. The fit fall of using setter when class invariant is not checked/violated and how to solve it.
  6. Shallow vs deep copy and how to ensure a deep copy with copy constructor and op=.
  7. The benefit of using the “override” keyword.
  8. Using “=delete” keyword to disable a specific function, vs the old 98/03 “method”.
  9. Variadic Templates.
  10. Using sprintf vs iostream vs std::format.

That’s it for June 2024 session.

Thank you for reading!

Kobi

Leave a Reply