
What the ISO C++ committee added to C++17 working draft at Oulu 2016 meeting - nikbackm
https://www.reddit.com/r/cpp/comments/4pmlpz/what_the_iso_c_committee_added_to_the_c17_working/
======
vmorgulis
My favorite is "template<auto>". An universal smart pointer:

    
    
        template <typename T,auto f> struct smart
        {
         T* pointer=nullptr;
    
         ~smart(){f(pointer);}
        };
    
        smart<char,free> buffer={malloc(...)};
        smart<FILE*,fclose> file={fopen(...)};
        ...
    

Something to keep in the "potential subset".

[http://www.open-
std.org/jtc1/sc22/wg21/docs/papers/2016/p012...](http://www.open-
std.org/jtc1/sc22/wg21/docs/papers/2016/p0127r1.html)

