Explore the proposed C++14 language feature of template constraints, also known as concepts lite, in this comprehensive CppNow conference talk. Dive into the world of predicates that determine template argument compatibility, learning how to improve template declarations by explicitly stating requirements. Discover the power of function overloading based on constraints and how this feature can significantly reduce compiler error complexity. Examine the minimal and uncomplicated nature of template constraints, emphasizing correct template usage over definition correctness, and learn how to incrementally adopt them into existing codebases. Gain insights into practical applications of constraints in generic algorithms, data structures, member functions, constructors, overloading, and class template specialization. Benefit from the speaker's personal experiences using constraints in day-to-day programming, including both successful and less effective approaches. Take advantage of the opportunity to experiment with an available GCC-4.8-based compiler featuring this new language feature.
Overview
Syllabus
Andrew Sutton: Concepts Lite: Constraining Templates with Predicates
Taught by
CppNow