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 template make_variant_over

boost::make_variant_over —

Exposes a variant whose bounded types are the elements of the given type sequence.


template<typename Sequence> 
class make_variant_over {
// types
typedef variant< unspecified > type;


type has behavior equivalent in every respect to variant< Sequence[0], Sequence[1], ... > (where Sequence[i] denotes the i-th element of Sequence), except that no upper limit is imposed on the number of types.


  • Sequence must meet the requirements of MPL's Sequence concept.
  • Due to standard conformance problems in several compilers, make_variant_over may not be supported on your compiler. See BOOST_VARIANT_NO_TYPE_SEQUENCE_SUPPORT for more information.
Copyright 2002, 2003 Eric Friedman, Itay Maman