Boost C++ Libraries 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 for the latest Boost documentation.

Class optional_last_value<void>

boost::signals2::optional_last_value<void> — Evaluate an InputIterator sequence.


// In header: <boost/signals2/optional_last_value.hpp>

class optional_last_value<void> {
  // types
  typedef void result_type;

  // invocation
  template<typename InputIterator> 
    result_type operator()(InputIterator, InputIterator) const;


This specialization of signals2::optional_last_value is provided to cope with the fact that there is no such thing as an optional<void>, which optional_last_value would otherwise try to use as its result_type. This specialization instead sets the result_type to be void.

optional_last_value invocation

  1. template<typename InputIterator> 
      result_type operator()(InputIterator first, InputIterator last) const;


    Attempts to dereference every iterator in the sequence [first, last).