So far, this is all I've been able to come up with:
#include
, boost::mpl::pair
> glTypeMap;
};
template< typename t_type >
struct Vertex
{
static const unsigned int type = boost::mpl::at
Hi,
I'm looking for a complete compile-time constant map container that uses types as keys and integral constants as values. For example:
typedef map< pair
, pair > mapType; unsigned int value = get_value ::value; The above code is PSEUDO CODE only. It is supposed to give you an idea of what I'm looking for. I tried using boost::fusion::map, however the fusion::pair object expects a TYPE as the second template argument, so I can't specify integral values. Could someone provide a code example that achieves the above? Note that I should be able to do the following as well:
typedef map< pair
, pair > mapType; class foo { // This would result in 'value' being the integral number 90. static const unsigned int value = get_value
::value; }