Aug 3, 2018 at 8:44pm
Hi,
I recently learned that you can accept any container by using a template like so:
1 2 3 4 5
|
template <typename T>
void SomeFunc(T container)
{
container.insert(container.end(), 1);
}
|
But i was wondering: is there a way to "require" that container to be of a specific type itself?
something like
template <typename T<int>>
?
Last edited on Aug 3, 2018 at 8:46pm