Advancing cppfront with Modern C++: Refining the Implementation of is, as, and UFCS
Talkat CppCon 2023 · on Thursday, 2023-10-05· at 14:00· Cottonwood 2/3, 6700 North Gaylord Rockies Boulevard·
summary
Implements 'is', 'as', and UFCS in cppfront using Modern C++ with concrete compiler constraints (GCC 10, Clang 12/13/14, MSVC), builds overloaded functions plus special-case handlers for variant/optional/any, and ships workarounds for generic lambdas and implicit casts. Uses concept subsumption rules heavily, debugs with Compiler Explorer, and avoids static_assert inside requires by returning std::true_type/std::false_type or std::nullopt. Result: functioning pull request with working UFCS macros and some compiler-dependent hacks and fallbacks.
AI-written summary · about
chapters (15)
- 0:00Advancing cppfront with Modern C++
- 1:05Contributing to cppfront
- 3:18is operator implementation
- 6:08C++20 concepts and subsumption
- 12:58Implementing is for types
- 20:37Refining is with concepts
- 27:28Handling emptiness in is
- 30:20Passing concepts to functions
- 36:32Type find if for variants
- 43:41as operator use cases
- 47:30Identity function in as
- 51:49Perfect forwarding in as
- 55:43Takeaways from is and as
- 56:46Exploring UFCS
- 1:00:19Q&A on cppfront
related talks
01h 47mFunctional C++
56m“Modern C++ Interfaces..."
01h 03m“Programming with C++ Constraints: Background, Utility, and Gotchas"
01h 07mConcepts As She Is Spoke
01h 39m“Concepts: The Future of Generic Programming (the future is here)”
55mCustom Overload Sets and Inline SFINAE for Truly Generic Interfaces
01h 02mC++20 Concepts
59mThe Best Parts of C++
