It turns out it's quite easy to enable compile time support when implementing the builder pattern using concepts and boost::hana. Every add method can only be called exactly once - and the build method can only be called after all adders were called. And with a trick we can even avoid unnecessary memory operations at runtime. Hana also allows us to generate compile time error messages.
Keywords: builder pattern, boost::hana, concepts, metaprogramming, type based state machines
Preparation: 2 week
Duration: 25-30 mins