Boost C++ Libraries Home Libraries People FAQ More

PrevUpHomeNext

Struct template default_eval

boost::proto::context::default_eval — A BinaryFunction that accepts a Proto expression and a context, evaluates each child expression with the context, and combines the result using the standard C++ meaning for the operator represented by the current expression node.

Synopsis

// In header: <boost/proto/context/default.hpp>

template<typename Expr, typename Context> 
struct default_eval {
  // types
  typedef  ;          // For exposition only
  typedef                ;

  // public member functions
   (, ) ;

  // public data members
  static  s_expr;  // For exposition only
  static  s_context;  // For exposition only
};

Description

Let OP be the C++ operator corresponding to Expr::proto_tag. (For example, if Tag is proto::tag::plus, let OP be +.)

The behavior of this class is specified in terms of the C++0x decltype keyword. In systems where this keyword is not available, Proto uses the Boost.Typeof library to approximate the behavior.

default_eval public types

  1. typedef ;

default_eval public member functions

  1.  ( expr,  context) ;

    Parameters:

    context

    The evaluation context

    expr

    The current expression


PrevUpHomeNext