diff options
author | Murray Cumming <murrayc@murrayc.com> | 2016-03-03 12:55:50 +0100 |
---|---|---|
committer | Murray Cumming <murrayc@murrayc.com> | 2016-03-03 12:55:50 +0100 |
commit | 0af06bb9703f67a07316153983361a70b7c53757 (patch) | |
tree | 3e9a504d8869b0ce68b8767b8819e4d647def29a | |
parent | 8fa0a162a35223d4b7467b04f7f6cc0e202034c6 (diff) | |
download | sigc++-0af06bb9703f67a07316153983361a70b7c53757.tar.gz |
Remove use of removed SIGC_HAVE_SUN_REVERSE_ITERATOR
-rw-r--r-- | sigc++/signal.h | 20 | ||||
-rw-r--r-- | tests/test_accum_iter.cc | 4 |
2 files changed, 1 insertions, 23 deletions
diff --git a/sigc++/signal.h b/sigc++/signal.h index 9a36575..0938720 100644 --- a/sigc++/signal.h +++ b/sigc++/signal.h @@ -182,17 +182,8 @@ struct slot_list typedef slot_iterator<slot_type> iterator; typedef slot_const_iterator<slot_type> const_iterator; - #ifndef SIGC_HAVE_SUN_REVERSE_ITERATOR typedef std::reverse_iterator<iterator> reverse_iterator; typedef std::reverse_iterator<const_iterator> const_reverse_iterator; - #else - typedef std::reverse_iterator<iterator, std::random_access_iterator_tag, - int, int&, int*, std::ptrdiff_t> reverse_iterator; - - typedef std::reverse_iterator<const_iterator, std::random_access_iterator_tag, - int, const int&, const int*, std::ptrdiff_t> const_reverse_iterator; - #endif /* SIGC_HAVE_SUN_REVERSE_ITERATOR */ - slot_list() : list_(nullptr) {} @@ -750,12 +741,7 @@ struct signal_emit<T_return, void, T_arg...> //Use this scope to make sure that "slots" is destroyed before "exec" is destroyed. //This avoids a leak on MSVC++ - see http://bugzilla.gnome.org/show_bug.cgi?id=306249 { -#ifndef SIGC_HAVE_SUN_REVERSE_ITERATOR typedef std::reverse_iterator<signal_impl::iterator_type> reverse_iterator_type; -#else - typedef std::reverse_iterator<signal_impl::iterator_type, std::random_access_iterator_tag, - slot_base, slot_base&, slot_base*, std::ptrdiff_t> reverse_iterator_type; -#endif temp_slot_list slots(impl->slots_); reverse_iterator_type it(slots.end()); @@ -819,12 +805,8 @@ struct signal_emit<void, void, T_arg...> signal_exec exec(impl); temp_slot_list slots(impl->slots_); -#ifndef SIGC_HAVE_SUN_REVERSE_ITERATOR typedef std::reverse_iterator<signal_impl::iterator_type> reverse_iterator_type; -#else - typedef std::reverse_iterator<signal_impl::iterator_type, std::random_access_iterator_tag, - slot_base, slot_base&, slot_base*, std::ptrdiff_t> reverse_iterator_type; -#endif + for (reverse_iterator_type it = reverse_iterator_type(slots.end()); it != reverse_iterator_type(slots.begin()); ++it) { if (it->empty() || it->blocked()) diff --git a/tests/test_accum_iter.cc b/tests/test_accum_iter.cc index b5947ec..640d39a 100644 --- a/tests/test_accum_iter.cc +++ b/tests/test_accum_iter.cc @@ -20,11 +20,7 @@ struct min_accum typedef T result_type; template<class I> -#ifndef SIGC_HAVE_SUN_REVERSE_ITERATOR typename std::iterator_traits<I>::value_type operator()(I i1, I i2) -#else - typename I::value_type operator()(I i1, I i2) -#endif { return *std::min_element(i1, i2); } |