Boost logo

Boost-Commit :

Subject: [Boost-commit] svn:boost r57378 - in sandbox/SOC/2009/fusion/boost/fusion/view: filter_view/detail joint_view/detail nview nview/detail nview/detail/pp repetitive_view repetitive_view/detail reverse_view/detail single_view/detail transform_view/detail zip_view/detail
From: mr.chr.schmidt_at_[hidden]
Date: 2009-11-04 15:14:48


Author: cschmidt
Date: 2009-11-04 15:14:45 EST (Wed, 04 Nov 2009)
New Revision: 57378
URL: http://svn.boost.org/trac/boost/changeset/57378

Log:
correct propagation of cv-ref-qual. to view iterators
Text files modified:
   sandbox/SOC/2009/fusion/boost/fusion/view/filter_view/detail/begin_impl.hpp | 7 +++++--
   sandbox/SOC/2009/fusion/boost/fusion/view/filter_view/detail/end_impl.hpp | 7 +++++--
   sandbox/SOC/2009/fusion/boost/fusion/view/joint_view/detail/begin_impl.hpp | 16 ++++++++++++----
   sandbox/SOC/2009/fusion/boost/fusion/view/joint_view/detail/end_impl.hpp | 9 +++++++--
   sandbox/SOC/2009/fusion/boost/fusion/view/joint_view/detail/joint_view_iterator.hpp | 39 +++++++++++++++++++++++++++++++++++++--
   sandbox/SOC/2009/fusion/boost/fusion/view/joint_view/detail/next_impl.hpp | 4 ++--
   sandbox/SOC/2009/fusion/boost/fusion/view/nview/detail/advance_impl.hpp | 2 +-
   sandbox/SOC/2009/fusion/boost/fusion/view/nview/detail/begin_impl.hpp | 2 +-
   sandbox/SOC/2009/fusion/boost/fusion/view/nview/detail/end_impl.hpp | 2 +-
   sandbox/SOC/2009/fusion/boost/fusion/view/nview/detail/next_impl.hpp | 2 +-
   sandbox/SOC/2009/fusion/boost/fusion/view/nview/detail/nview_iterator.hpp | 35 +++++++++++++++++++++++++++++++++--
   sandbox/SOC/2009/fusion/boost/fusion/view/nview/detail/pp/as_nview.hpp | 3 +++
   sandbox/SOC/2009/fusion/boost/fusion/view/nview/detail/prior_impl.hpp | 2 +-
   sandbox/SOC/2009/fusion/boost/fusion/view/nview/nview.hpp | 3 +++
   sandbox/SOC/2009/fusion/boost/fusion/view/repetitive_view/detail/advance_impl.hpp | 6 +++---
   sandbox/SOC/2009/fusion/boost/fusion/view/repetitive_view/detail/next_impl.hpp | 3 +--
   sandbox/SOC/2009/fusion/boost/fusion/view/repetitive_view/detail/prior_impl.hpp | 3 +--
   sandbox/SOC/2009/fusion/boost/fusion/view/repetitive_view/repetitive_view.hpp | 18 ++++++++++++++++++
   sandbox/SOC/2009/fusion/boost/fusion/view/reverse_view/detail/advance_impl.hpp | 2 +-
   sandbox/SOC/2009/fusion/boost/fusion/view/reverse_view/detail/begin_impl.hpp | 9 +++++++--
   sandbox/SOC/2009/fusion/boost/fusion/view/reverse_view/detail/end_impl.hpp | 9 +++++++--
   sandbox/SOC/2009/fusion/boost/fusion/view/reverse_view/detail/next_impl.hpp | 2 +-
   sandbox/SOC/2009/fusion/boost/fusion/view/reverse_view/detail/prior_impl.hpp | 2 +-
   sandbox/SOC/2009/fusion/boost/fusion/view/reverse_view/detail/reverse_view_iterator.hpp | 20 ++++++++++++++++++--
   sandbox/SOC/2009/fusion/boost/fusion/view/single_view/detail/single_view_iterator.hpp | 17 +++++++++++++++++
   sandbox/SOC/2009/fusion/boost/fusion/view/transform_view/detail/begin_impl.hpp | 21 ++++++++++++++++++---
   sandbox/SOC/2009/fusion/boost/fusion/view/transform_view/detail/end_impl.hpp | 21 ++++++++++++++++++---
   sandbox/SOC/2009/fusion/boost/fusion/view/zip_view/detail/end_impl.hpp | 7 ++-----
   28 files changed, 225 insertions(+), 48 deletions(-)

Modified: sandbox/SOC/2009/fusion/boost/fusion/view/filter_view/detail/begin_impl.hpp
==============================================================================
--- sandbox/SOC/2009/fusion/boost/fusion/view/filter_view/detail/begin_impl.hpp (original)
+++ sandbox/SOC/2009/fusion/boost/fusion/view/filter_view/detail/begin_impl.hpp 2009-11-04 15:14:45 EST (Wed, 04 Nov 2009)
@@ -23,12 +23,15 @@
         struct apply
         {
             typedef typename detail::remove_reference<Seq>::type seq;
+ typedef typename
+ detail::forward_as<Seq, typename seq::seq_type>::type
+ underlying_seq_type;
 
             typedef
                 filter_iterator<
                     typename seq::category
- , typename result_of::begin<typename seq::seq_type>::type
- , typename result_of::end<typename seq::seq_type>::type
+ , typename result_of::begin<underlying_seq_type>::type
+ , typename result_of::end<underlying_seq_type>::type
                   , typename seq::pred_type
>
             type;

Modified: sandbox/SOC/2009/fusion/boost/fusion/view/filter_view/detail/end_impl.hpp
==============================================================================
--- sandbox/SOC/2009/fusion/boost/fusion/view/filter_view/detail/end_impl.hpp (original)
+++ sandbox/SOC/2009/fusion/boost/fusion/view/filter_view/detail/end_impl.hpp 2009-11-04 15:14:45 EST (Wed, 04 Nov 2009)
@@ -22,12 +22,15 @@
         struct apply
         {
             typedef typename detail::remove_reference<Seq>::type seq;
+ typedef typename
+ detail::forward_as<Seq, typename seq::seq_type>::type
+ underlying_seq_type;
 
             typedef
                 filter_iterator<
                     typename seq::category
- , typename result_of::end<typename seq::seq_type>::type
- , typename result_of::end<typename seq::seq_type>::type
+ , typename result_of::end<underlying_seq_type>::type
+ , typename result_of::end<underlying_seq_type>::type
                   , typename seq::pred_type
>
             type;

Modified: sandbox/SOC/2009/fusion/boost/fusion/view/joint_view/detail/begin_impl.hpp
==============================================================================
--- sandbox/SOC/2009/fusion/boost/fusion/view/joint_view/detail/begin_impl.hpp (original)
+++ sandbox/SOC/2009/fusion/boost/fusion/view/joint_view/detail/begin_impl.hpp 2009-11-04 15:14:45 EST (Wed, 04 Nov 2009)
@@ -28,13 +28,21 @@
         {
             typedef typename detail::remove_reference<Seq>::type seq;
             typedef typename
- result_of::begin<typename seq::seq1_type>::type
+ detail::forward_as<Seq, typename seq::seq1_type>::type
+ underlying_seq1_type;
+ typedef typename
+ result_of::begin<underlying_seq1_type>::type
             begin_type;
             typedef typename
- result_of::end<typename seq::seq1_type>::type
+ result_of::end<underlying_seq1_type>::type
             end_type;
             typedef typename
- result_of::begin<typename seq::seq2_type>::type
+ result_of::begin<
+ typename detail::forward_as<
+ Seq
+ , typename seq::seq2_type
+ >::type
+ >::type
             concat_type;
             typedef typename
                 result_of::equal_to<begin_type, end_type>::type
@@ -56,7 +64,7 @@
             static type
             call(Seq seq, mpl::true_)
             {
- return type(fusion::begin(seq.seq2.get()));
+ return type(fusion::begin(seq.seq2.get()),0);
             }
 
             static type

Modified: sandbox/SOC/2009/fusion/boost/fusion/view/joint_view/detail/end_impl.hpp
==============================================================================
--- sandbox/SOC/2009/fusion/boost/fusion/view/joint_view/detail/end_impl.hpp (original)
+++ sandbox/SOC/2009/fusion/boost/fusion/view/joint_view/detail/end_impl.hpp 2009-11-04 15:14:45 EST (Wed, 04 Nov 2009)
@@ -29,14 +29,19 @@
             typedef
                 concat_iterator<
                     typename seq::category
- , typename result_of::end<typename seq::seq2_type>::type
+ , typename result_of::end<
+ typename detail::forward_as<
+ Seq
+ , typename seq::seq2_type
+ >::type
+ >::type
>
             type;
 
             static type
             call(Seq seq)
             {
- return type(fusion::end(seq.seq2.get()));
+ return type(fusion::end(seq.seq2.get()),0);
             }
         };
     };

Modified: sandbox/SOC/2009/fusion/boost/fusion/view/joint_view/detail/joint_view_iterator.hpp
==============================================================================
--- sandbox/SOC/2009/fusion/boost/fusion/view/joint_view/detail/joint_view_iterator.hpp (original)
+++ sandbox/SOC/2009/fusion/boost/fusion/view/joint_view/detail/joint_view_iterator.hpp 2009-11-04 15:14:45 EST (Wed, 04 Nov 2009)
@@ -27,11 +27,30 @@
         typedef joint_view_iterator_tag fusion_tag;
         typedef Category category;
 
+ template<typename OtherIt>
+ joint_view_iterator(BOOST_FUSION_R_ELSE_CLREF(OtherIt) it)
+ : first(BOOST_FUSION_FORWARD(OtherIt,it).first)
+ , concat(BOOST_FUSION_FORWARD(OtherIt,it).concat)
+ {
+ BOOST_FUSION_TAG_CHECK(OtherIt,joint_view_iterator_tag);
+ }
+
         joint_view_iterator(Begin const& first, Concat const& concat)
           : first(first)
           , concat(concat)
         {}
 
+ template<typename OtherIt>
+ joint_view_iterator&
+ operator=(BOOST_FUSION_R_ELSE_CLREF(OtherIt) it)
+ {
+ BOOST_FUSION_TAG_CHECK(OtherIt,joint_view_iterator_tag);
+
+ first=BOOST_FUSION_FORWARD(OtherIt,it).first;
+ concat=BOOST_FUSION_FORWARD(OtherIt,it).concat;
+ return *this;
+ }
+
         begin_type first;
         concat_type concat;
     };
@@ -45,11 +64,27 @@
         typedef concat_iterator_tag fusion_tag;
         typedef Category category;
 
- explicit
- concat_iterator(Begin const& first)
+ template<typename OtherIt>
+ concat_iterator(BOOST_FUSION_R_ELSE_CLREF(OtherIt) it)
+ : first(BOOST_FUSION_FORWARD(OtherIt,it).first)
+ {
+ BOOST_FUSION_TAG_CHECK(OtherIt,concat_iterator_tag);
+ }
+
+ concat_iterator(Begin const& first,int)
           : first(first)
         {}
 
+ template<typename OtherIt>
+ concat_iterator&
+ operator=(BOOST_FUSION_R_ELSE_CLREF(OtherIt) it)
+ {
+ BOOST_FUSION_TAG_CHECK(OtherIt,concat_iterator_tag);
+
+ first=BOOST_FUSION_FORWARD(OtherIt,it).first;
+ return *this;
+ }
+
         begin_type first;
     };
 }}

Modified: sandbox/SOC/2009/fusion/boost/fusion/view/joint_view/detail/next_impl.hpp
==============================================================================
--- sandbox/SOC/2009/fusion/boost/fusion/view/joint_view/detail/next_impl.hpp (original)
+++ sandbox/SOC/2009/fusion/boost/fusion/view/joint_view/detail/next_impl.hpp 2009-11-04 15:14:45 EST (Wed, 04 Nov 2009)
@@ -50,7 +50,7 @@
             static type
             call(It it, mpl::true_)
             {
- return type(it.concat);
+ return type(it.concat,0);
             }
 
             static type
@@ -85,7 +85,7 @@
             static type
             call(It it)
             {
- return type(fusion::next(it.first));
+ return type(fusion::next(it.first),0);
             }
         };
     };

Modified: sandbox/SOC/2009/fusion/boost/fusion/view/nview/detail/advance_impl.hpp
==============================================================================
--- sandbox/SOC/2009/fusion/boost/fusion/view/nview/detail/advance_impl.hpp (original)
+++ sandbox/SOC/2009/fusion/boost/fusion/view/nview/detail/advance_impl.hpp 2009-11-04 15:14:45 EST (Wed, 04 Nov 2009)
@@ -33,7 +33,7 @@
             static type
             call(It it)
             {
- return type(it.seq);
+ return type(it.seq,0);
             }
         };
     };

Modified: sandbox/SOC/2009/fusion/boost/fusion/view/nview/detail/begin_impl.hpp
==============================================================================
--- sandbox/SOC/2009/fusion/boost/fusion/view/nview/detail/begin_impl.hpp (original)
+++ sandbox/SOC/2009/fusion/boost/fusion/view/nview/detail/begin_impl.hpp 2009-11-04 15:14:45 EST (Wed, 04 Nov 2009)
@@ -35,7 +35,7 @@
             static type
             call(Seq seq)
             {
- return type(seq.seq.get());
+ return type(seq.seq.get(),0);
             }
         };
     };

Modified: sandbox/SOC/2009/fusion/boost/fusion/view/nview/detail/end_impl.hpp
==============================================================================
--- sandbox/SOC/2009/fusion/boost/fusion/view/nview/detail/end_impl.hpp (original)
+++ sandbox/SOC/2009/fusion/boost/fusion/view/nview/detail/end_impl.hpp 2009-11-04 15:14:45 EST (Wed, 04 Nov 2009)
@@ -35,7 +35,7 @@
             static type
             call(Seq seq)
             {
- return type(seq.seq.get());
+ return type(seq.seq.get(),0);
             }
         };
     };

Modified: sandbox/SOC/2009/fusion/boost/fusion/view/nview/detail/next_impl.hpp
==============================================================================
--- sandbox/SOC/2009/fusion/boost/fusion/view/nview/detail/next_impl.hpp (original)
+++ sandbox/SOC/2009/fusion/boost/fusion/view/nview/detail/next_impl.hpp 2009-11-04 15:14:45 EST (Wed, 04 Nov 2009)
@@ -33,7 +33,7 @@
             static type
             call(It it)
             {
- return type(it.seq);
+ return type(it.seq,0);
             }
         };
     };

Modified: sandbox/SOC/2009/fusion/boost/fusion/view/nview/detail/nview_iterator.hpp
==============================================================================
--- sandbox/SOC/2009/fusion/boost/fusion/view/nview/detail/nview_iterator.hpp (original)
+++ sandbox/SOC/2009/fusion/boost/fusion/view/nview/detail/nview_iterator.hpp 2009-11-04 15:14:45 EST (Wed, 04 Nov 2009)
@@ -10,6 +10,11 @@
 #define BOOST_FUSION_VIEW_NVIEW_DETAIL_NVIEW_ITERATOR_HPP
 
 #include <boost/fusion/support/iterator_base.hpp>
+#include <boost/fusion/support/internal/assert.hpp>
+
+#ifdef BOOST_FUSION_ENABLE_STATIC_ASSERTS
+# include <boost/mpl/eqaul_to.hpp>
+#endif
 
 namespace boost { namespace fusion
 {
@@ -25,11 +30,37 @@
         typedef nview_iterator_tag fusion_tag;
         typedef random_access_traversal_tag category;
 
- explicit
- nview_iterator(SeqRef seq)
+ template<typename OtherIt>
+ nview_iterator(BOOST_FUSION_R_ELSE_CLREF(OtherIt) it)
+ : seq(BOOST_FUSION_FORWARD(OtherIt,it).seq)
+ {
+ BOOST_FUSION_TAG_CHECK(OtherIt,nview_iterator_tag);
+ BOOST_FUSION_MPL_ASSERT((
+ mpl::equal_to<
+ Pos
+ , detail::remove_reference<OtherIt>::type::pos_type
+ >));
+ }
+
+ nview_iterator(SeqRef seq,int)
           : seq(seq)
         {}
 
+ template<typename OtherIt>
+ nview_iterator&
+ operator=(BOOST_FUSION_R_ELSE_CLREF(OtherIt) it)
+ {
+ BOOST_FUSION_TAG_CHECK(OtherIt,nview_iterator_tag);
+ BOOST_FUSION_MPL_ASSERT((
+ mpl::equal_to<
+ Pos
+ , detail::remove_reference<OtherIt>::type::pos_type
+ >));
+
+ seq=BOOST_FUSION_FORWARD(OtherIt,it).seq;
+ return *this;
+ }
+
         SeqRef seq;
     };
 

Modified: sandbox/SOC/2009/fusion/boost/fusion/view/nview/detail/pp/as_nview.hpp
==============================================================================
--- sandbox/SOC/2009/fusion/boost/fusion/view/nview/detail/pp/as_nview.hpp (original)
+++ sandbox/SOC/2009/fusion/boost/fusion/view/nview/detail/pp/as_nview.hpp 2009-11-04 15:14:45 EST (Wed, 04 Nov 2009)
@@ -26,6 +26,9 @@
>
 #endif
         {
+ BOOST_FUSION_MPL_ASSERT((traits::is_sequence<Seq>));
+ BOOST_FUSION_MPL_ASSERT((traits::is_random_access<Seq>));
+
             typedef
                 nview<
                     Seq

Modified: sandbox/SOC/2009/fusion/boost/fusion/view/nview/detail/prior_impl.hpp
==============================================================================
--- sandbox/SOC/2009/fusion/boost/fusion/view/nview/detail/prior_impl.hpp (original)
+++ sandbox/SOC/2009/fusion/boost/fusion/view/nview/detail/prior_impl.hpp 2009-11-04 15:14:45 EST (Wed, 04 Nov 2009)
@@ -33,7 +33,7 @@
             static type
             call(It it)
             {
- return type(it.seq);
+ return type(it.seq,0);
             }
         };
     };

Modified: sandbox/SOC/2009/fusion/boost/fusion/view/nview/nview.hpp
==============================================================================
--- sandbox/SOC/2009/fusion/boost/fusion/view/nview/nview.hpp (original)
+++ sandbox/SOC/2009/fusion/boost/fusion/view/nview/nview.hpp 2009-11-04 15:14:45 EST (Wed, 04 Nov 2009)
@@ -116,6 +116,9 @@
         template<class Seq, int... Indices>
         struct as_nview
         {
+ BOOST_FUSION_MPL_ASSERT((traits::is_sequence<Seq>));
+ BOOST_FUSION_MPL_ASSERT((traits::is_random_access<Seq>));
+
             typedef
                 nview<
                     Seq

Modified: sandbox/SOC/2009/fusion/boost/fusion/view/repetitive_view/detail/advance_impl.hpp
==============================================================================
--- sandbox/SOC/2009/fusion/boost/fusion/view/repetitive_view/detail/advance_impl.hpp (original)
+++ sandbox/SOC/2009/fusion/boost/fusion/view/repetitive_view/detail/advance_impl.hpp 2009-11-04 15:14:45 EST (Wed, 04 Nov 2009)
@@ -41,7 +41,7 @@
             type;
 
             static type
- call(It const& it)
+ call(It& it)
             {
                 return fusion::advance<N>(it.it);
             }
@@ -65,7 +65,7 @@
             type;
 
             static type
- call(It const& it)
+ call(It& it)
             {
                 return fusion::advance<real_n>(fusion::begin(*it.seq));
             }
@@ -97,7 +97,7 @@
                 static type
                 call(It it)
                 {
- return type(it.seq.get(),gen::call(it));
+ return type(*it.seq,gen::call(it));
                 }
             };
         };

Modified: sandbox/SOC/2009/fusion/boost/fusion/view/repetitive_view/detail/next_impl.hpp
==============================================================================
--- sandbox/SOC/2009/fusion/boost/fusion/view/repetitive_view/detail/next_impl.hpp (original)
+++ sandbox/SOC/2009/fusion/boost/fusion/view/repetitive_view/detail/next_impl.hpp 2009-11-04 15:14:45 EST (Wed, 04 Nov 2009)
@@ -16,7 +16,6 @@
 
 #include <boost/mpl/eval_if.hpp>
 #include <boost/mpl/bool.hpp>
-#include <boost/mpl/next.hpp>
 #include <boost/mpl/equal_to.hpp>
 #include <boost/mpl/identity.hpp>
 
@@ -47,7 +46,7 @@
                       , result_of::begin<typename it::seq_type>
                       , mpl::identity<next_it>
>::type
- , mpl::next<typename it::index>::type::value
+ , it::index::value+1
>
             type;
 

Modified: sandbox/SOC/2009/fusion/boost/fusion/view/repetitive_view/detail/prior_impl.hpp
==============================================================================
--- sandbox/SOC/2009/fusion/boost/fusion/view/repetitive_view/detail/prior_impl.hpp (original)
+++ sandbox/SOC/2009/fusion/boost/fusion/view/repetitive_view/detail/prior_impl.hpp 2009-11-04 15:14:45 EST (Wed, 04 Nov 2009)
@@ -14,7 +14,6 @@
 #include <boost/fusion/iterator/equal_to.hpp>
 
 #include <boost/mpl/if.hpp>
-#include <boost/mpl/next.hpp>
 #include <boost/mpl/equal_to.hpp>
 
 namespace boost { namespace fusion { namespace extension
@@ -46,7 +45,7 @@
                           , typename it::it_type
>::type
>::type
- , mpl::next<typename it::index>::type::value
+ , it::index::value-1
>
             type;
 

Modified: sandbox/SOC/2009/fusion/boost/fusion/view/repetitive_view/repetitive_view.hpp
==============================================================================
--- sandbox/SOC/2009/fusion/boost/fusion/view/repetitive_view/repetitive_view.hpp (original)
+++ sandbox/SOC/2009/fusion/boost/fusion/view/repetitive_view/repetitive_view.hpp 2009-11-04 15:14:45 EST (Wed, 04 Nov 2009)
@@ -17,12 +17,18 @@
 #include <boost/fusion/support/sequence_base.hpp>
 #include <boost/fusion/support/internal/workaround.hpp>
 #include <boost/fusion/support/internal/assert.hpp>
+#ifdef BOOST_FUSION_ENABLE_STATIC_ASSERTS
+# include <boost/fusion/sequence/intrinsic/empty.hpp>
+#endif
 #include <boost/fusion/view/detail/view_storage.hpp>
 
 #include <boost/mpl/bool.hpp>
 #include <boost/mpl/long.hpp>
 #ifdef BOOST_FUSION_ENABLE_STATIC_ASSERTS
 # include <boost/mpl/eqaul_to.hpp>
+# include <boost/mpl/not.hpp>
+# include <boost/mpl/or_.hpp>
+# include <boost/mpl/bool.hpp>
 #endif
 #include <boost/integer_traits.hpp>
 
@@ -50,6 +56,11 @@
       : sequence_base<repetitive_view<Seq> >
     {
         BOOST_FUSION_MPL_ASSERT((traits::is_sequence<Seq>));
+ BOOST_FUSION_MPL_ASSERT((traits::is_forward<Seq>));
+ BOOST_FUSION_MPL_ASSERT((mpl::or_<
+ mpl:not_<result_of::empty<Seq> >
+ , mpl::bool_<!Size>
+ >));
 
         typedef detail::view_storage<Seq> storage_type;
         typedef typename storage_type::type seq_type;
@@ -107,6 +118,13 @@
         template<typename Seq, int Size=integer_traits<int>::const_max-1>
         struct repeat
         {
+ BOOST_FUSION_MPL_ASSERT((traits::is_sequence<Seq>));
+ BOOST_FUSION_MPL_ASSERT((traits::is_forward<Seq>));
+ BOOST_FUSION_MPL_ASSERT((mpl::or_<
+ mpl:not_<result_of::empty<Seq> >
+ , mpl::bool_<!Size>
+ >));
+
             typedef
                 repetitive_view<typename traits::deduce<Seq>::type, Size>
             type;

Modified: sandbox/SOC/2009/fusion/boost/fusion/view/reverse_view/detail/advance_impl.hpp
==============================================================================
--- sandbox/SOC/2009/fusion/boost/fusion/view/reverse_view/detail/advance_impl.hpp (original)
+++ sandbox/SOC/2009/fusion/boost/fusion/view/reverse_view/detail/advance_impl.hpp 2009-11-04 15:14:45 EST (Wed, 04 Nov 2009)
@@ -39,7 +39,7 @@
             static type
             call(It it)
             {
- return type(fusion::advance<neg_dist>(it.it));
+ return type(fusion::advance<neg_dist>(it.it),0);
             }
         };
     };

Modified: sandbox/SOC/2009/fusion/boost/fusion/view/reverse_view/detail/begin_impl.hpp
==============================================================================
--- sandbox/SOC/2009/fusion/boost/fusion/view/reverse_view/detail/begin_impl.hpp (original)
+++ sandbox/SOC/2009/fusion/boost/fusion/view/reverse_view/detail/begin_impl.hpp 2009-11-04 15:14:45 EST (Wed, 04 Nov 2009)
@@ -24,7 +24,12 @@
             typedef
                 reverse_view_iterator<
                     typename result_of::end<
- typename detail::remove_reference<Seq>::type::seq_type
+ typename detail::forward_as<
+ Seq
+ , typename detail::remove_reference<
+ Seq
+ >::type::seq_type
+ >::type
>::type
>
             type;
@@ -32,7 +37,7 @@
             static type
             call(Seq seq)
             {
- return type(fusion::end(seq.seq.get()));
+ return type(fusion::end(seq.seq.get()),0);
             }
         };
     };

Modified: sandbox/SOC/2009/fusion/boost/fusion/view/reverse_view/detail/end_impl.hpp
==============================================================================
--- sandbox/SOC/2009/fusion/boost/fusion/view/reverse_view/detail/end_impl.hpp (original)
+++ sandbox/SOC/2009/fusion/boost/fusion/view/reverse_view/detail/end_impl.hpp 2009-11-04 15:14:45 EST (Wed, 04 Nov 2009)
@@ -24,7 +24,12 @@
             typedef
                 reverse_view_iterator<
                     typename result_of::begin<
- typename detail::remove_reference<Seq>::type::seq_type
+ typename detail::forward_as<
+ Seq
+ , typename detail::remove_reference<
+ Seq
+ >::type::seq_type
+ >::type
>::type
>
             type;
@@ -32,7 +37,7 @@
             static type
             call(Seq seq)
             {
- return type(fusion::begin(seq.seq.get()));
+ return type(fusion::begin(seq.seq.get()),0);
             }
         };
     };

Modified: sandbox/SOC/2009/fusion/boost/fusion/view/reverse_view/detail/next_impl.hpp
==============================================================================
--- sandbox/SOC/2009/fusion/boost/fusion/view/reverse_view/detail/next_impl.hpp (original)
+++ sandbox/SOC/2009/fusion/boost/fusion/view/reverse_view/detail/next_impl.hpp 2009-11-04 15:14:45 EST (Wed, 04 Nov 2009)
@@ -31,7 +31,7 @@
             static type
             call(It it)
             {
- return type(fusion::prior(it.it));
+ return type(fusion::prior(it.it),0);
             }
         };
     };

Modified: sandbox/SOC/2009/fusion/boost/fusion/view/reverse_view/detail/prior_impl.hpp
==============================================================================
--- sandbox/SOC/2009/fusion/boost/fusion/view/reverse_view/detail/prior_impl.hpp (original)
+++ sandbox/SOC/2009/fusion/boost/fusion/view/reverse_view/detail/prior_impl.hpp 2009-11-04 15:14:45 EST (Wed, 04 Nov 2009)
@@ -31,7 +31,7 @@
             static type
             call(It it)
             {
- return type(fusion::next(it.it));
+ return type(fusion::next(it.it),0);
             }
         };
     };

Modified: sandbox/SOC/2009/fusion/boost/fusion/view/reverse_view/detail/reverse_view_iterator.hpp
==============================================================================
--- sandbox/SOC/2009/fusion/boost/fusion/view/reverse_view/detail/reverse_view_iterator.hpp (original)
+++ sandbox/SOC/2009/fusion/boost/fusion/view/reverse_view/detail/reverse_view_iterator.hpp 2009-11-04 15:14:45 EST (Wed, 04 Nov 2009)
@@ -24,11 +24,27 @@
         typedef reverse_view_iterator_tag fusion_tag;
         typedef typename traits::category_of<it_type>::type category;
 
- explicit
- reverse_view_iterator(It const& it)
+ template<typename OtherIt>
+ reverse_view_iterator(BOOST_FUSION_R_ELSE_CLREF(OtherIt) it)
+ : it(BOOST_FUSION_FORWARD(OtherIt,it).it)
+ {
+ BOOST_FUSION_TAG_CHECK(OtherIt,reverse_view_iterator_tag);
+ }
+
+ reverse_view_iterator(It const& it,int)
           : it(it)
         {}
 
+ template<typename OtherIt>
+ reverse_view_iterator&
+ operator=(BOOST_FUSION_R_ELSE_CLREF(OtherIt) it_)
+ {
+ BOOST_FUSION_TAG_CHECK(OtherIt,reverse_view_iterator_tag);
+
+ it=BOOST_FUSION_FORWARD(OtherIt,it_).it;
+ return *this;
+ }
+
         it_type it;
     };
 }}

Modified: sandbox/SOC/2009/fusion/boost/fusion/view/single_view/detail/single_view_iterator.hpp
==============================================================================
--- sandbox/SOC/2009/fusion/boost/fusion/view/single_view/detail/single_view_iterator.hpp (original)
+++ sandbox/SOC/2009/fusion/boost/fusion/view/single_view/detail/single_view_iterator.hpp 2009-11-04 15:14:45 EST (Wed, 04 Nov 2009)
@@ -30,11 +30,28 @@
         typedef single_view_iterator_tag fusion_tag;
         typedef random_access_traversal_tag category;
 
+ template<typename OtherIt>
+ single_view_iterator(BOOST_FUSION_R_ELSE_CLREF(OtherIt) it)
+ : val(BOOST_FUSION_FORWARD(OtherIt,it).val)
+ {
+ BOOST_FUSION_TAG_CHECK(OtherIt,single_view_iterator_tag);
+ }
+
         explicit
         single_view_iterator(value_ref_type val)
           : val(&val)
         {}
 
+ template<typename OtherIt>
+ single_view_iterator&
+ operator=(BOOST_FUSION_R_ELSE_CLREF(OtherIt) it)
+ {
+ BOOST_FUSION_TAG_CHECK(OtherIt,single_view_iterator_tag);
+
+ val=BOOST_FUSION_FORWARD(OtherIt,it).val;
+ return *this;
+ }
+
         typename detail::remove_reference<value_ref_type>::type* val;
     };
 }}

Modified: sandbox/SOC/2009/fusion/boost/fusion/view/transform_view/detail/begin_impl.hpp
==============================================================================
--- sandbox/SOC/2009/fusion/boost/fusion/view/transform_view/detail/begin_impl.hpp (original)
+++ sandbox/SOC/2009/fusion/boost/fusion/view/transform_view/detail/begin_impl.hpp 2009-11-04 15:14:45 EST (Wed, 04 Nov 2009)
@@ -29,7 +29,12 @@
 
             typedef
                 transform_view_iterator<
- typename result_of::begin<typename seq::seq_type>::type
+ typename result_of::begin<
+ typename detail::forward_as<
+ Seq
+ , typename seq::seq_type
+ >::type
+ >::type
                   , typename detail::forward_as<
                         Seq
                       , typename seq::transform_type
@@ -57,8 +62,18 @@
 
             typedef
                 transform_view_iterator2<
- typename result_of::begin<typename seq::seq1_type>::type
- , typename result_of::begin<typename seq::seq2_type>::type
+ typename result_of::begin<
+ typename detail::forward_as<
+ Seq
+ , typename seq::seq1_type
+ >::type
+ >::type
+ , typename result_of::begin<
+ typename detail::forward_as<
+ Seq
+ , typename seq::seq2_type
+ >::type
+ >::type
                   , typename detail::forward_as<
                         Seq
                       , typename seq::transform_type

Modified: sandbox/SOC/2009/fusion/boost/fusion/view/transform_view/detail/end_impl.hpp
==============================================================================
--- sandbox/SOC/2009/fusion/boost/fusion/view/transform_view/detail/end_impl.hpp (original)
+++ sandbox/SOC/2009/fusion/boost/fusion/view/transform_view/detail/end_impl.hpp 2009-11-04 15:14:45 EST (Wed, 04 Nov 2009)
@@ -27,7 +27,12 @@
 
             typedef
                 transform_view_iterator<
- typename result_of::end<typename seq::seq_type>::type
+ typename result_of::end<
+ typename detail::forward_as<
+ Seq
+ , typename seq::seq_type
+ >::type
+ >::type
                   , typename detail::forward_as<
                         Seq
                       , typename seq::transform_type
@@ -55,8 +60,18 @@
 
             typedef
                 transform_view_iterator2<
- typename result_of::end<typename seq::seq1_type>::type
- , typename result_of::end<typename seq::seq2_type>::type
+ typename result_of::end<
+ typename detail::forward_as<
+ Seq
+ , typename seq::seq1_type
+ >::type
+ >::type
+ , typename result_of::end<
+ typename detail::forward_as<
+ Seq
+ , typename seq::seq2_type
+ >::type
+ >::type
                   , typename detail::forward_as<
                         Seq
                       , typename seq::transform_type

Modified: sandbox/SOC/2009/fusion/boost/fusion/view/zip_view/detail/end_impl.hpp
==============================================================================
--- sandbox/SOC/2009/fusion/boost/fusion/view/zip_view/detail/end_impl.hpp (original)
+++ sandbox/SOC/2009/fusion/boost/fusion/view/zip_view/detail/end_impl.hpp 2009-11-04 15:14:45 EST (Wed, 04 Nov 2009)
@@ -27,11 +27,8 @@
     {
         template<typename Seq, typename M>
         struct get_endpoint
- {
- typedef typename result_of::begin<Seq>::type begin;
-
- typedef typename result_of::advance<begin, M>::type type;
- };
+ : result_of::advance<typename result_of::begin<Seq>::type, M>
+ {};
 
         template<typename M>
         struct endpoints


Boost-Commit list run by bdawes at acm.org, david.abrahams at rcn.com, gregod at cs.rpi.edu, cpdaniel at pacbell.net, john at johnmaddock.co.uk