samedi 29 juillet 2017

Does const and & in std::function ignored?

Why does this code compile?

std::function<void(const int&)> f = [](int a)
{

};

Aren't int and const int& different types?

Aucun commentaire:

Enregistrer un commentaire