KnowledgeHub
Questions
Tags
Users
Search
Alex Rivera
|
Logout
Edit Question
Title
Body
If I am allowed to do the following: template <typename T = int> class Foo{ }; why am I not allowed to do the following in a place like main: Foo me; but must instead specify the following? Foo<int> me; C++11 introduced default template arguments, and, right now, I'm finding them difficult to fully understand.
Tags (comma-separated)
Save Edits
Cancel