I have a std::tuple that contains holds different pointers:
std::tuple<int*, double*> foo;
Now I want to visit all elements in foo
and perform an action on every element that is not nullptr
. For this I could roll a template loop, but it would be much nicer with a solution based on std::apply
or fold a fold expression.