Namespaces
Variants
Views
Actions

Talk:cpp/thread/scoped lock

From cppreference.com

std::scoped_lock does not exist in C++ 17 I think a new variant of std::lock_guard is meant that can accept multiple mutexes. See: http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2015/p0156r0.html 217.86.132.73 03:12, 6 January 2017 (PST)

The current plan is to rename the variadic version of lock_guard to scoped_lock, because making lock_guard variadic breaks ABI. But yes, we are jumping the gun a little here. (I did something similar with removing default_order, but IMO there's a difference between not documenting a (mis-)feature that is likely going away, and documenting something that isn't certain to go in yet as if it is already in - imagine if we did the same thing with STL's for(i : v)...) T. Canens (talk) 03:18, 6 January 2017 (PST)
I didn't know that and I cannot find anything in the Web about it. Perhaps there should be a hint that this is not the currently published name but some future name. 217.86.132.73 07:51, 6 January 2017 (PST)
It's published in http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2016/p0156r1.html --Cubbi (talk) 07:56, 6 January 2017 (PST)