template <typename Function> void for_each_element(
const boost::tuples::null_type&, Function) {}
template <typename Tuple, typename Function> void
for_each_element(Tuple& t, Function func) {
func(t.get_head());
for_each_element(t.get_tail(),func);
}
Given the above code snippet, do we define a overload function or a partially specialized function?
Thank you
There’s no such thing as a function partial specialisation. It’s an overload.
e.g.
Be careful when mixing specialisations with overloads, as it doesn’t always work the way you may think it does.