bug fixes to segmented fusion support, more fwd headers

[SVN r73927]
This commit is contained in:
Eric Niebler
2011-08-19 18:41:11 +00:00
parent eb903d71a7
commit def510808d
18 changed files with 286 additions and 22 deletions

View File

@ -122,7 +122,7 @@ namespace boost { namespace fusion { namespace detail
>
type;
static type call(Stack stack)
static type call(Stack const& stack)
{
//return segment_sequence(
// push_front(
@ -168,7 +168,7 @@ namespace boost { namespace fusion { namespace detail
>
type;
static type call(Stack stack)
static type call(Stack const& stack)
{
// return iterator_range(begin(car(cdr(stack_begin))), end(front(car(stack_begin))));
return type(stack.cdr.car.first, fusion::end(*stack.car.first));
@ -178,10 +178,11 @@ namespace boost { namespace fusion { namespace detail
template <typename Stack>
struct make_segment_sequence_front<Stack, 1>
{
typedef nil type;
static type call(Stack const &)
typedef typename Stack::cdr_type type; // nil
static type call(Stack const &stack)
{
return nil();
return stack.cdr;
}
};
@ -264,7 +265,7 @@ namespace boost { namespace fusion { namespace detail
>
type;
static type call(Stack stack)
static type call(Stack const& stack)
{
// return segment_sequence(
// push_back(
@ -310,7 +311,7 @@ namespace boost { namespace fusion { namespace detail
>
type;
static type call(Stack stack)
static type call(Stack const& stack)
{
// return iterator_range(begin(front(car(stack_end))), begin(car(cdr(stack_end))));
return type(fusion::begin(*stack.car.first), stack.cdr.car.first);
@ -320,10 +321,11 @@ namespace boost { namespace fusion { namespace detail
template <typename Stack>
struct make_segment_sequence_back<Stack, 1>
{
typedef nil type;
static type call(Stack const &)
typedef typename Stack::cdr_type type; // nil
static type call(Stack const& stack)
{
return nil();
return stack.cdr;
}
};
@ -490,7 +492,7 @@ namespace boost { namespace fusion { namespace detail
typedef typename impl::type type;
static type call(Begin const & begin, End const & end)
static type call(Begin const& begin, End const& end)
{
return impl::call(
reverse_begin_cons::call(begin.context)

View File

@ -7,6 +7,7 @@
#if !defined(FUSION_JOINT_VIEW_07162005_0140)
#define FUSION_JOINT_VIEW_07162005_0140
#include <boost/fusion/view/joint_view/joint_view_fwd.hpp>
#include <boost/fusion/support/detail/access.hpp>
#include <boost/fusion/support/is_view.hpp>
#include <boost/fusion/sequence/intrinsic/begin.hpp>

View File

@ -0,0 +1,18 @@
/*=============================================================================
Copyright (c) 2011 Eric Niebler
Distributed under the Boost Software License, Version 1.0. (See accompanying
file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
==============================================================================*/
#if !defined(BOOST_FUSION_JOINT_VIEW_FWD_HPP_INCLUDED)
#define BOOST_FUSION_JOINT_VIEW_FWD_HPP_INCLUDED
namespace boost { namespace fusion
{
struct joint_view_tag;
template <typename Sequence1, typename Sequence2>
struct joint_view;
}}
#endif