libstdc++-v3-gcc-4.8.5

git-svn-id: svn://kolibrios.org@6325 a494cfbc-eb01-0410-851d-a64ba20cac60
This commit is contained in:
Sergey Semyonov (Serge)
2016-03-12 09:38:51 +00:00
parent 3b53803119
commit d73a7e667d
68 changed files with 2581 additions and 3307 deletions

View File

@@ -2181,8 +2181,15 @@ _GLIBCXX_HAS_NESTED_TYPE(result_type)
using _Invoke = decltype(__callable_functor(std::declval<_Functor&>())
(std::declval<_ArgTypes>()...) );
// Used so the return type convertibility checks aren't done when
// performing overload resolution for copy construction/assignment.
template<typename _Tp>
using _NotSelf = __not_<is_same<_Tp, function>>;
template<typename _Functor>
using _Callable = __check_func_return_type<_Invoke<_Functor>, _Res>;
using _Callable
= __and_<_NotSelf<_Functor>,
__check_func_return_type<_Invoke<_Functor>, _Res>>;
template<typename _Cond, typename _Tp>
using _Requires = typename enable_if<_Cond::value, _Tp>::type;
@@ -2323,7 +2330,7 @@ _GLIBCXX_HAS_NESTED_TYPE(result_type)
* reference_wrapper<F>, this function will not throw.
*/
template<typename _Functor>
_Requires<_Callable<_Functor>, function&>
_Requires<_Callable<typename decay<_Functor>::type>, function&>
operator=(_Functor&& __f)
{
function(std::forward<_Functor>(__f)).swap(*this);
@@ -2432,9 +2439,9 @@ _GLIBCXX_HAS_NESTED_TYPE(result_type)
{
if (static_cast<bool>(__x))
{
__x._M_manager(_M_functor, __x._M_functor, __clone_functor);
_M_invoker = __x._M_invoker;
_M_manager = __x._M_manager;
__x._M_manager(_M_functor, __x._M_functor, __clone_functor);
}
}