While we wait for CppCon 2015 in September, we’re featuring videos of some of the 100+ talks from CppCon 2014. Here is today’s feature:
Metaprogramming with Boost.Hana: Unifying Boost.Fusion and Boost.MPL
by Louis Dionne
Summary of the talk:
Template metaprogramming sucks. No, seriously; you might like the imposed purely functional paradigm, but not the templates themselves. While C++11 has made our life easier, even simple metaprograms are often hard to write, impossible to maintain and slow to compile; we need better abstractions. In this talk, I will present Boost.Hana, an experimental C++14 library for heterogeneous computation. The library takes metaprogramming to a whole new level of expressiveness by unifying the well-known Boost.MPL and Boost.Fusion libraries under a single generic, purely functional interface. The library incorporates some of the most recent advances in C++ metaprogramming; I will give an overview of the most interesting implementation techniques used internally. Finally, I will show concrete ways to use the library so you, as a developer, can write less template black magic, increase your productivity and spend less time in coffee breaks waiting for the compiler (sorry).