|  | Home | Libraries | People | FAQ | More | 
Returns the type stored at the position of an iterator.
template< typename I > struct value_of { typedef unspecified type; };
Table 1.11. Parameters
| Parameter | Requirement | Description | 
|---|---|---|
| 
                     | Model of Forward Iterator | Operation's argument | 
result_of::value_of<I>::type
Return type: Any type
          Semantics: Returns the type stored in
          a sequence at iterator position I.
        
#include <boost/fusion/iterator/value_of.hpp> #include <boost/fusion/include/value_of.hpp>
typedefvector<int,int&,const int&> vec; typedefresult_of::begin<vec>::type first; typedefresult_of::next<first>::type second; typedefresult_of::next<second>::type third; BOOST_MPL_ASSERT((boost::is_same<result_of::value_of<first>::type, int>)); BOOST_MPL_ASSERT((boost::is_same<result_of::value_of<second>::type, int&>)); BOOST_MPL_ASSERT((boost::is_same<result_of::value_of<third>::type, const int&>));