Boost logo

Boost Users :

Subject: [Boost-users] [mpl::integral_c] Compiler Error with Visual Studio 2010
From: Christian Henning (chhenning_at_[hidden])
Date: 2013-02-04 16:04:44


Hi there,

shouldn't the following work:

#include <boost\gil\gil_all.hpp>

using namespace std;
using namespace boost;

int main()
{
    typedef mpl::integral_c< unsigned char
                           , numeric_limits< unsigned char >::max()
> my_max_value_t;

    return 0;
}

Visual Studio 2010 gives me:

error C2975: 'N' : invalid template argument for
'boost::mpl::integral_c', expected compile-time constant expression

I'm a little surprised that this isn't working.

Thanks,
Christian


Boost-users list run by williamkempf at hotmail.com, kalb at libertysoft.com, bjorn.karlsson at readsoft.com, gregod at cs.rpi.edu, wekempf at cox.net