<% render(instance) %> <%= includes(x) %> #include template struct result { }; struct f { template constexpr result operator()(X) const { return {}; } }; template struct x { }; int main() { auto go = boost::hana::fmap(f{}, <%= list((0..x).map { |i| "x<#{i}>" }, (0..x).map { |i| "x<#{i}>{}" }) %> ); }