C++20 Lambdas: Familiar Template Syntax
summary
C++20 adds a template head to lambdas so code that used helper functions just to destructure types can be replaced by an immediately-invoked familiar template lambda, collapsing the std::apply helper and tuple-for-each patterns into a single expression. Examples show unary and binary tuple algorithms using non-type template parameter packs and reference-capture preserves forwarding/value-category. Result is substantially less boilerplate, fewer identifiers, and working, more compact code for tuple and typelist destructuring.
AI-written summary · about
related talks
01h 21mWhat Has C++20 Ever Done For Templates?
01h 27mC++20 Templates - the Next Level: Concepts and More
01h 23mHow C++20 Can Simplify std::tuple
59mLambdas from First Principles: A Whirlwind Tour of C++""
51mA Tale of Two Tuples - A Story of the C++ Revolution
50mExpression Templates: Past, Present, Future
01h 31mImplementing variant Visitation Using Lambdas
04mGeneralized fold expressions
