vendredi 3 mars 2017

Why there is no templated typedef in C++11?

Why the Committee decided not to approve templated typedef along with templated using?

template <class T>
using my_vector = std::vector<T>;

is legal.

But

template <class T>
typedef std::vector<T> my_vector<T>;

is illegal?

Aucun commentaire:

Enregistrer un commentaire