Higher Order Functions for ordinary developers
summary
Shows how to write and compose C++14 higher-order functions that return lambdas (concrete examples: equals, compose, when_all, if_then) and claims compilers inline them into essentially zero-cost abstractions. Demonstrates assembly to back the performance claim, uses a TL::optional variant with and_then/or_else style extensions, and offers a tiny lift macro to pass overload sets. Notes Boost 1.67 overlap is small, provides a drop-in utility set, and warns about triggering compiler bugs on extremely generic, constexpr/perfect-forwarding code.
AI-written summary · about
chapters (3)
related talks
56mBack to Basics: Functional Programming and Monads in C++
01h 01mModern C++ Error Handling
01h 03mModern C++ Development: Limitations and Problems in std::function and Similar Constructs
33mCode Factorization: How to Organize Boilerplate Code
01h 00mThe hidden rules of world-class C++ code
47mReducing Template Compilation Overhead, Using C++11, 14, 17, and 20.
31mLet's get Functional (en)
01h 02mHow to Hide C++ Implementation Details
