| Home | Libraries | People | FAQ | More

## Struct reverse

boost::proto::functional::reverse — A PolymorphicFunctionObject type that invokes the `fusion::reverse()` algorithm on its argument.

## Synopsis

    // In header: <boost/proto/fusion.hpp>

    struct reverse :  proto::callable {
      // member classes/structs/unions
      template<typename This, typename Expr>
      struct result<This(Expr)> :
        fusion::result_of::reverse<
          typename boost::remove_reference< Expr >::type const
        >
      {
      };

      // public member functions
      template<typename Expr>
        typename fusion::result_of::reverse< Expr const  >::type
        operator()(Expr const &) const;
    };

## Description

A PolymorphicFunctionObject type that invokes the `fusion::reverse()` algorithm on its argument. This is useful for defining a CallableTransform like `reverse(_)`, which reverses the order of the children of a Proto expression node.

### `reverse` public member functions

1.     template<typename Expr>
         typename fusion::result_of::reverse< Expr const  >::type
         operator()(Expr const & expr) const;