[libsigcplusplus] test_accum_iter: Use of decltype(auto).
- From: Murray Cumming <murrayc src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [libsigcplusplus] test_accum_iter: Use of decltype(auto).
- Date: Thu, 21 Apr 2016 18:07:12 +0000 (UTC)
commit 999b9050964bb00ba1f72bea29a113b111adefb9
Author: Murray Cumming <murrayc murrayc com>
Date: Thu Apr 21 19:51:27 2016 +0200
test_accum_iter: Use of decltype(auto).
tests/test_accum_iter.cc | 3 ++-
1 files changed, 2 insertions(+), 1 deletions(-)
---
diff --git a/tests/test_accum_iter.cc b/tests/test_accum_iter.cc
index 81ada50..a4fe697 100644
--- a/tests/test_accum_iter.cc
+++ b/tests/test_accum_iter.cc
@@ -25,7 +25,8 @@ struct min_accum
using result_type = T;
template <typename I>
- typename std::iterator_traits<I>::value_type operator()(I i1, I i2)
+ decltype(auto)
+ operator()(I i1, I i2)
{
return *std::min_element(i1, i2);
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]