diff --git a/README.md b/README.md index 4f00064..cc9942f 100644 --- a/README.md +++ b/README.md @@ -75,14 +75,15 @@ C++11 includes the following new library features: ### Template argument deduction for class templates Automatic template argument deduction much like how it's done for functions, but now including class constructors. ```c++ -template +template struct MyContainer { T val; + MyContainer() : val() {} MyContainer(T val) : val(val) {} // ... }; MyContainer c1{ 1 }; // OK MyContainer -MyContainer c2; // OK MyContainer<> +MyContainer c2; // OK MyContainer ``` ### Declaring non-type template parameters with auto