decltype(auto) -> auto

This commit is contained in:
Sébastien Loriot 2021-02-02 10:58:31 +01:00
parent f69be333f0
commit 5da7e84bab
2 changed files with 5 additions and 6 deletions

View File

@ -291,8 +291,7 @@ bounding_box_2(ForwardIterator f, ForwardIterator l, const Traits& t)
} // bounding_box_2(f, l, t)
template < class ForwardIterator >
inline
//typename std::iterator_traits< ForwardIterator >::value_type::R::Iso_rectangle_2
decltype(auto)
auto
bounding_box_2(ForwardIterator f, ForwardIterator l)
// PRE: f != l.
{

View File

@ -358,7 +358,7 @@ public:
Unary_compose_1(const Op1& x, const Op2& y) : op1(x), op2(y) {}
template <typename argument_type>
decltype(auto)
auto
operator()(const argument_type& x) const
{ return op1(op2(x)); }
};
@ -381,7 +381,7 @@ public:
: op1(x), op2(y), op3(z) {}
template <typename argument_type>
decltype(auto)
auto
operator()(const argument_type& x) const
{ return op1(op2(x), op3(x)); }
};
@ -402,7 +402,7 @@ public:
Unary_compose_2(const Op1& x, const Op2& y) : op1(x), op2(y) {}
template <typename first_argument_type, typename second_argument_type>
decltype(auto)
auto
operator()(const first_argument_type& x,
const second_argument_type& y) const
{ return op1(op2(x, y)); }
@ -440,7 +440,7 @@ public:
}
template <typename first_argument_type, typename second_argument_type>
decltype(auto)
auto
operator()(const first_argument_type& x,
const second_argument_type& y) const
{ return op1(op2(x), op3(y)); }