Boost C++ Libraries

...one of the most highly regarded and expertly designed C++ library projects in the world. Herb Sutter and Andrei Alexandrescu, C++ Coding Standards

This is the documentation for an old version of Boost. Click here to view this page for the latest version.
PrevUpHomeNext

Struct template env

boost::proto::env

Synopsis

// In header: <boost/proto/transform/env.hpp>

template<typename Key, typename Value, typename Env = proto::empty_env> 
struct env {
  // construct/copy/destruct
  explicit env(Value const &, Env const & = Env());

  // public member functions
  see-below operator[](see-below) const;
};

Description

env public construct/copy/destruct

  1. explicit env(Value const & value, Env const & other = Env());

    Parameters:

    other

    Another key/value store.

    value

    The value to be associated with the Key.

env public member functions

  1. see-below operator[](see-below) const;

    If called with an object that is implicitly convertible to type Key, this function returns the Value passed to the constructor. Otherwise, it returns the result of calling operator[] on the Env passed to the constructor.


PrevUpHomeNext