Example:
#include <iostream>
#include <boost/call_traits.hpp>
#include <type_traits>
boost::call_traits<int>::param_type f()
{
return 1;
}
int main()
{
std::cout << std::boolalpha;
std::cout <<
std::is_const<boost::call_traits<int>::param_type>::value
<< std::endl; // true
std::cout << std::is_const<decltype(f())>::value << std::endl; // false
}
Question:
Unless, I am doing something wrong, I think I should be getting true
for both, but gcc 4.7.0 outputs false
for the latter. Is there something I am missing?