[libcxx] r191142 - Apply LWG 2048. It is amazing to me that this actually works, but the existing tests confirm that it does. c++1y status page now showing libc++ is complete for c++1y modulo dynarray issues.

Howard Hinnant hhinnant at apple.com
Sat Sep 21 12:25:37 PDT 2013


Author: hhinnant
Date: Sat Sep 21 14:25:37 2013
New Revision: 191142

URL: http://llvm.org/viewvc/llvm-project?rev=191142&view=rev
Log:
Apply LWG 2048.  It is amazing to me that this actually works, but the existing tests confirm that it does.  c++1y status page now showing libc++ is complete for c++1y modulo dynarray issues.

Modified:
    libcxx/trunk/include/functional
    libcxx/trunk/www/cxx1y_status.html

Modified: libcxx/trunk/include/functional
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/include/functional?rev=191142&r1=191141&r2=191142&view=diff
==============================================================================
--- libcxx/trunk/include/functional (original)
+++ libcxx/trunk/include/functional Sat Sep 21 14:25:37 2013
@@ -358,18 +358,6 @@ template <class S, class T>          con
 template <class S, class T, class A> const_mem_fun1_ref_t<S,T,A> mem_fun_ref(S (T::*f)(A) const);
 
 template<class R, class T> unspecified mem_fn(R T::*);
-template<class R, class T, class... Args> unspecified mem_fn(R (T::*)(Args...));
-template<class R, class T, class... Args> unspecified mem_fn(R (T::*)(Args...) const);
-template<class R, class T, class... Args> unspecified mem_fn(R (T::*)(Args...) volatile);
-template<class R, class T, class... Args> unspecified mem_fn(R (T::*)(Args...) const volatile);
-template<class R, class T, class... Args> unspecified mem_fn(R (T::*)(Args...) &);
-template<class R, class T, class... Args> unspecified mem_fn(R (T::*)(Args...) const &);
-template<class R, class T, class... Args> unspecified mem_fn(R (T::*)(Args...) volatile &);
-template<class R, class T, class... Args> unspecified mem_fn(R (T::*)(Args...) const volatile &);
-template<class R, class T, class... Args> unspecified mem_fn(R (T::*)(Args...) &&);
-template<class R, class T, class... Args> unspecified mem_fn(R (T::*)(Args...) const &&);
-template<class R, class T, class... Args> unspecified mem_fn(R (T::*)(Args...) volatile &&);
-template<class R, class T, class... Args> unspecified mem_fn(R (T::*)(Args...) const volatile &&);
 
 class bad_function_call
     : public exception
@@ -1207,38 +1195,6 @@ mem_fn(_Rp _Tp::* __pm)
     return __mem_fn<_Rp _Tp::*>(__pm);
 }
 
-template<class _Rp, class _Tp, class ..._Args>
-inline _LIBCPP_INLINE_VISIBILITY
-__mem_fn<_Rp (_Tp::*)(_Args...)>
-mem_fn(_Rp (_Tp::* __pm)(_Args...))
-{
-    return __mem_fn<_Rp (_Tp::*)(_Args...)>(__pm);
-}
-
-template<class _Rp, class _Tp, class ..._Args>
-inline _LIBCPP_INLINE_VISIBILITY
-__mem_fn<_Rp (_Tp::*)(_Args...) const>
-mem_fn(_Rp (_Tp::* __pm)(_Args...) const)
-{
-    return __mem_fn<_Rp (_Tp::*)(_Args...) const>(__pm);
-}
-
-template<class _Rp, class _Tp, class ..._Args>
-inline _LIBCPP_INLINE_VISIBILITY
-__mem_fn<_Rp (_Tp::*)(_Args...) volatile>
-mem_fn(_Rp (_Tp::* __pm)(_Args...) volatile)
-{
-    return __mem_fn<_Rp (_Tp::*)(_Args...) volatile>(__pm);
-}
-
-template<class _Rp, class _Tp, class ..._Args>
-inline _LIBCPP_INLINE_VISIBILITY
-__mem_fn<_Rp (_Tp::*)(_Args...) const volatile>
-mem_fn(_Rp (_Tp::* __pm)(_Args...) const volatile)
-{
-    return __mem_fn<_Rp (_Tp::*)(_Args...) const volatile>(__pm);
-}
-
 // bad_function_call
 
 class _LIBCPP_EXCEPTION_ABI bad_function_call

Modified: libcxx/trunk/www/cxx1y_status.html
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/www/cxx1y_status.html?rev=191142&r1=191141&r2=191142&view=diff
==============================================================================
--- libcxx/trunk/www/cxx1y_status.html (original)
+++ libcxx/trunk/www/cxx1y_status.html Sat Sep 21 14:25:37 2013
@@ -134,7 +134,7 @@
 	<tr><td><a href="http://www.open-std.org/jtc1/sc22/wg21/docs/lwg-defects.html#2123">2123</a></td><td>merge() allocator requirements for lists versus forward lists</td><td>Portland</td><td>Complete</td></tr>
 	<tr><td><a href="http://www.open-std.org/jtc1/sc22/wg21/docs/lwg-defects.html#2005">2005</a></td><td>unordered_map::insert(T&&) protection should apply to map too</td><td>Portland</td><td>Complete</td></tr>
 	<tr><td><a href="http://www.open-std.org/jtc1/sc22/wg21/docs/lwg-defects.html#2011">2011</a></td><td>Unexpected output required of strings</td><td>Portland</td><td>Complete</td></tr>
-	<tr><td><a href="http://www.open-std.org/jtc1/sc22/wg21/docs/lwg-defects.html#2048">2048</a></td><td>Unnecessary mem_fn overloads</td><td>Portland</td><td></td></tr>
+	<tr><td><a href="http://www.open-std.org/jtc1/sc22/wg21/docs/lwg-defects.html#2048">2048</a></td><td>Unnecessary mem_fn overloads</td><td>Portland</td><td>Complete</td></tr>
 	<tr><td><a href="http://www.open-std.org/jtc1/sc22/wg21/docs/lwg-defects.html#2049">2049</a></td><td>is_destructible is underspecified</td><td>Portland</td><td>Complete</td></tr>
 	<tr><td><a href="http://www.open-std.org/jtc1/sc22/wg21/docs/lwg-defects.html#2056">2056</a></td><td>future_errc enums start with value 0 (invalid value for broken_promise)</td><td>Portland</td><td>Complete</td></tr>
 	<tr><td><a href="http://www.open-std.org/jtc1/sc22/wg21/docs/lwg-defects.html#2058">2058</a></td><td>valarray and begin/end</td><td>Portland</td><td>Complete</td></tr>





More information about the cfe-commits mailing list