2 Jul
2016
2 Jul
'16
4:28 p.m.
Bjorn Reese wrote:
A simpler patch is to make m_x static.
That would produce a compilation error: `1 / 0` is not a constant expression. The downside of using non-static data member is that `mpl::print` no longer gives warning with a typedef `typedef mpl::print<Foo> X;`. We need a variable `mpl::print<Foo> x;` to produce warning. The "deprecated" attribute might be a better way to produce warning. But I fail to apply that attribute to class templates. Regards, Michel