Remove unneded instantiation
Improve naming of is_single macro
Remove unneeded parameter from conditional macro
Simplify generation fo code using function builder