functor: style

This commit is contained in:
Danny Robson 2020-02-25 16:15:21 +11:00
parent ebb99a6f4e
commit 1e3c342482

View File

@ -29,12 +29,12 @@ namespace cruft::functor {
/// A trivial functor that wraps std::begin without any static typing. /// A trivial functor that wraps std::begin without any static typing.
struct begin { struct begin {
template <typename valuet> template <typename ValueT>
decltype (auto) decltype (auto)
operator() (valuet &&value) noexcept (noexcept (std::begin (value))) operator() (ValueT &&value) noexcept (noexcept (std::begin (value)))
{ {
return std::begin ( return std::begin (
std::forward<valuet> (value) std::forward<ValueT> (value)
); );
} }
}; };
@ -42,12 +42,12 @@ namespace cruft::functor {
/// A trivial functor that wraps std::end without any static typing. /// A trivial functor that wraps std::end without any static typing.
struct end { struct end {
template <typename valuet> template <typename ValueT>
decltype (auto) decltype (auto)
operator() (valuet &&value) noexcept (noexcept (std::end (value))) operator() (ValueT &&value) noexcept (noexcept (std::end (value)))
{ {
return std::end ( return std::end (
std::forward<valuet> (value) std::forward<ValueT> (value)
); );
} }
}; };