summaryrefslogtreecommitdiff
path: root/src/optional.hh
diff options
context:
space:
mode:
authorSidharth Kshatriya <sid.kshatriya@gmail.com>2023-03-15 12:34:12 +0530
committerSidharth Kshatriya <sid.kshatriya@gmail.com>2023-03-15 12:34:12 +0530
commitf41f3781e1df7a9a64a05cc65e22488b7aa18d6d (patch)
tree8a8f64215acf4042dd21cc2d82b8f985d1471c4c /src/optional.hh
parent019fbc5439ad884f172c324ebc928463eab9bc74 (diff)
Remove && from the template parameter given to declval
It seems redundant as declval already returns a rvalue reference
Diffstat (limited to 'src/optional.hh')
-rw-r--r--src/optional.hh2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/optional.hh b/src/optional.hh
index e9386fa8..81dd15cf 100644
--- a/src/optional.hh
+++ b/src/optional.hh
@@ -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 {};