...one of the most highly
regarded and expertly designed C++ library projects in the
world.
— Herb Sutter and Andrei
Alexandrescu, C++
Coding Standards
This module provides adapters for std::pair
.
Including the module header makes std::pair
a fully conforming Random
Access Sequence.
#include <boost/fusion/adapted/std_pair.hpp> #include <boost/fusion/include/std_pair.hpp>
std::pair<int, std::string> p(123, "Hola!!!"); std::cout <<at_c
<0>(p) << std::endl; std::cout <<at_c
<1>(p) << std::endl; std::cout << p << std::endl;