Remove && from the template parameter given to declval

It seems redundant as declval already returns a rvalue reference
This commit is contained in:
Sidharth Kshatriya 2023-03-15 12:34:12 +05:30
parent 019fbc5439
commit f41f3781e1

View File

@ -95,7 +95,7 @@ public:
template<typename U> using DecayOptional = typename DecayOptionalImpl<U>::Type;
template<typename F>
auto map(F f) -> Optional<DecayOptional<decltype(f(std::declval<T&&>()))>>
auto map(F f) -> Optional<DecayOptional<decltype(f(std::declval<T>()))>>
{
if (not m_valid)
return {};