Boost  v1.57.0
doxygen for www.boost.org
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Modules Pages
boost::proto::make< Object > Struct Template Reference

A PrimitiveTransform which computes a type by evaluating any nested transforms and then constructs an object of that type. More...

#include <make.hpp>

Inheritance diagram for boost::proto::make< Object >:
Collaboration diagram for boost::proto::make< Object >:

Classes

struct  impl
 

Public Types

typedef make< Object > transform_type
 

Public Member Functions

 BOOST_PROTO_CALLABLE () typedef X proto_is_transform_
 
BOOST_FORCEINLINE
boost::proto::detail::apply_transform
< transform_type(Expr const &)>
::result_type 
operator() (Expr &&e) const
 
BOOST_FORCEINLINE
boost::proto::detail::apply_transform
< transform_type(Expr const
&, State const &)>
::result_type 
operator() (Expr &&e, State &&s) const
 
BOOST_FORCEINLINE
boost::proto::detail::apply_transform
< transform_type(Expr const
&, State const &, Data const &)>
::result_type 
operator() (Expr &&e, State &&s, Data &&d) const
 

Detailed Description

template<typename Object>
struct boost::proto::make< Object >

A PrimitiveTransform which computes a type by evaluating any nested transforms and then constructs an object of that type.

The make<> transform checks to see if Object is a template. If it is, the template type is disassembled to find nested transforms. Proto considers the following types to represent transforms:

boost::result_of<make<T<X0,X1,...> >(Expr, State, Data)>::type is evaluated as follows. For each X in X0,X1,..., do:

  • If X is a template like U<Y0,Y1,...>, then let X' be boost::result_of<make<U<Y0,Y1,...> >(Expr, State, Data)>::type (which evaluates this procedure recursively). Note whether any substitutions took place during this operation.
  • Otherwise, if X is a transform, then let X' be boost::result_of<when<_, X>(Expr, State, Data)>::type. Note that a substitution took place.
  • Otherwise, let X' be X, and note that no substitution took place.
  • If any substitutions took place in any of the above steps and T<X0',X1',...> has a nested ::type typedef, the result type is T<X0',X1',...>::type.
  • Otherwise, the result type is T<X0',X1',...>.

Note that when<> is implemented in terms of call<> and make<>, so the above procedure is evaluated recursively.

Member Typedef Documentation

typedef make< Object > boost::proto::transform< make< Object > , X >::transform_type
inherited

Member Function Documentation

boost::proto::transform< make< Object > , X >::BOOST_PROTO_CALLABLE ( )
inherited
BOOST_FORCEINLINE boost::proto::detail::apply_transform<transform_type(Expr const &, State const &, Data const &)>::result_type boost::proto::transform< make< Object > , X >::operator() ( Expr &&  e,
State &&  s,
Data &&  d 
) const
inlineinherited
BOOST_FORCEINLINE boost::proto::detail::apply_transform<transform_type(Expr const &, State const &)>::result_type boost::proto::transform< make< Object > , X >::operator() ( Expr &&  e,
State &&  s 
) const
inlineinherited
BOOST_FORCEINLINE boost::proto::detail::apply_transform<transform_type(Expr const &)>::result_type boost::proto::transform< make< Object > , X >::operator() ( Expr &&  e) const
inlineinherited

The documentation for this struct was generated from the following file: