diff --git a/include/boost/fusion/algorithm/iteration/ext_/fold_s.hpp b/include/boost/fusion/algorithm/iteration/ext_/fold_s.hpp index 78d5d8e8..13908f97 100644 --- a/include/boost/fusion/algorithm/iteration/ext_/fold_s.hpp +++ b/include/boost/fusion/algorithm/iteration/ext_/fold_s.hpp @@ -23,7 +23,7 @@ namespace boost { namespace fusion { namespace detail { typedef fusion::result< - typename result_of::fold::type, + typename result_of::fold::type, continue_ > type; @@ -37,7 +37,7 @@ namespace boost { namespace fusion { namespace detail typename result::type operator()(Range& rng, State const& state, Context const&) const { - return fusion::fold(rng, state.value, fun); + return fusion::fold(rng, state, fun); } Fun const& fun; diff --git a/include/boost/fusion/view/ext_/segmented_fold_until.hpp b/include/boost/fusion/view/ext_/segmented_fold_until.hpp index 85392073..799da3cd 100644 --- a/include/boost/fusion/view/ext_/segmented_fold_until.hpp +++ b/include/boost/fusion/view/ext_/segmented_fold_until.hpp @@ -216,12 +216,16 @@ namespace boost { namespace fusion struct segmented_fold_until_impl { typedef - typename boost::result_of::type + typename boost::result_of::type>::type, + Context const& + )>::type type; static type call(Range& rng, State const& state, Context const& context, Fun const& fun) { - return fun(rng, state, context); + return fun(rng, state.value, context); } }; diff --git a/include/boost/fusion/view/ext_/segmented_iterator_range.hpp b/include/boost/fusion/view/ext_/segmented_iterator_range.hpp index 209faee5..57de282d 100644 --- a/include/boost/fusion/view/ext_/segmented_iterator_range.hpp +++ b/include/boost/fusion/view/ext_/segmented_iterator_range.hpp @@ -539,7 +539,6 @@ namespace boost { namespace fusion { namespace extension }; }; - // TODO: remove invocation of distance in iterator_range. // TODO: default implementation of begin, end, and size // should check if the sequence is segmented and to // the right thing.