diff --git a/include/boost/coroutine2/detail/pull_coroutine.hpp b/include/boost/coroutine2/detail/pull_coroutine.hpp index 96d10d6..767a388 100644 --- a/include/boost/coroutine2/detail/pull_coroutine.hpp +++ b/include/boost/coroutine2/detail/pull_coroutine.hpp @@ -130,6 +130,9 @@ public: }; friend class iterator; + + iterator begin() { return iterator (this); } + iterator end() { return iterator(); } }; template< typename T > @@ -238,6 +241,9 @@ public: }; friend class iterator; + + iterator begin() { return iterator (this); } + iterator end() { return iterator(); } }; template<> @@ -278,6 +284,8 @@ public: explicit operator bool() const noexcept; bool operator!() const noexcept; + + }; template< typename T > @@ -294,22 +302,6 @@ end( pull_coroutine< T > &) { }}} -namespace std { - -template< typename T > -typename boost::coroutines2::detail::pull_coroutine< T >::iterator -begin( boost::coroutines2::detail::pull_coroutine< T > & c) { - return boost::coroutines2::detail::begin( c); -} - -template< typename T > -typename boost::coroutines2::detail::pull_coroutine< T >::iterator -end( boost::coroutines2::detail::pull_coroutine< T > & c) { - return boost::coroutines2::detail::end( c); -} - -} - #ifdef BOOST_HAS_ABI_HEADERS # include BOOST_ABI_SUFFIX #endif