Loading…
CppCon 2018 has ended
Friday, September 28 • 09:00 - 10:00
Class template argument deduction in C++17

Sign up or log in to save this to your schedule and see who's attending!

Class Template Argument Deduction (CTAD) is a very useful C++ language feature that was added in C++17. This talk is a comprehensive and practice-oriented introduction to this new technique.

In this talk I'll present how CATD and automatic deduction guides let you write cleaner and shorter code, show how to interact with it when using the C++ standard library and when designing your own classes, explain when and how user-defined deduction guides should be used, and cover the language rules behind all of this.

We will also discuss the various pitfalls that lie in wait: wrong and surprising template arguments being deduced, your constructor not being selected even if you think it should be, and automatic CTAD sometimes leading to unsafe and broken code – and how to circumnavigate those pitfalls.

Speakers
avatar for Timur Doumler

Timur Doumler

Timur Doumler is a C++ developer specialising in audio and music technology, active member of the ISO C++ committee, and part of the includecpp.org team. He is passionate about building communities, clean code, good tools, and the evolution of C++.


Friday September 28, 2018 09:00 - 10:00
Steamboat (403)

Attendees (126)