I got confused with the location where the ...
should be put when using template parameter packs.
For example, in template parameter list, we should use typename ...Ts
, while in a parameter list, it becomes Ts...ts
.
When instantiate a template, it becomes tuple<Ts...>
and most confused me is std::forward<Args>(args)...
, the ...
is out side the parentheses. Until then, I force myself to just remember this, until today I see this: sizeof...(Params)
, I think I must understand the regular pattern to avoid further confused.
So could anybody help how to treat the ...
to fully understand the location where to put it?