
19 Aug
2010
19 Aug
'10
2:55 p.m.
AMDG Thomas Heller wrote:
I just noticed something i find very odd. Considering this example:
mpl::add<mpl::int_<1>, mpl::int_<1>::type
So I was expecting that this metafunction returns a mpl::int<2> Unfortunately, this was not the case, instead a mpl::integral_c<int, 2> was returned. Is this a bug or a feature?
This is the expected behavior. In general, MPL makes no guarantees about the exact types resulting from operations. In Christ, Steven Watanabe