1 Apr
2010
1 Apr
'10
8:23 a.m.
It seems like the operators define in boost::numeric::functional takes reference as argument instead of const reference. Which makes it compile error if I use boost::numeric::functional::plus<int, int> op; int n = op(1,1); The way to work around is boost::numeric::functional::plus<const int, const int> op; int n = op(1,1); This is very ugly and not makes much sense, compared to std::plus. So is it a design flaw or is there some other reason for designing it in this way?