I\'d like to build a base (abstract) class (let\'s call it type::base) with some common funcionality and a fluent interface, the problem I\'m facing is the retu
type::base
One solution would work like this:
return *static_cast(&my_type().with_foo().with_bar());
Using static_cast basically tells the compiler 'I know what I'm doing here'.
static_cast