Le 21/04/13 17:45, John Maddock a écrit :
I'm not against this radical alternative, and I even like it. I don't know which compilers need the enum workaround and if Boost should support them.
The list seems to be:
VC7 and earlier Vacpp 5.02 and earlier (currently 11.1) Sunpro 5.6 and earlier. MPW all versions?
What I want is just that integral_constant use them so that all the traits in Boost conforms to the C++11 standard.
Out of curiosity, can you detect the difference? What can you do with constexpr values that you can't with static const ones?
Even if most of the uses of integral_constant is to use its member
::value integral constant defines also the operator(), so it is a
nullary functor.
integral_constant