Using template type with default type without angle brackets

What is this feature (being able to omit angle brackets) called and in what version of C++ was this introduced?

This (somewhat controversial) feature is called class template argument deduction (short: CTAD) and has been introduced with C++17. You can read about it here. If you compile this snippet with e.g. -std=c++14, it won’t compile.

CLICK HERE to find out more related problems solutions.

Leave a Comment

Your email address will not be published.

Scroll to Top