Вот такое приводит к ошибке на msvc2010
#include <boost/function.hpp>
#include <boost/function_types/parameter_types.hpp>
#include <boost/mpl/at.hpp>
template<class Func>
struct MsgT {
typedef typename boost::function_types::parameter_types<decltype(&Func::operator())>::type paramTypes;
typedef typename boost::mpl::at<paramTypes, boost::mpl::int_<1> >::type Arg0;
};
error C2146: syntax error : missing ';' before identifier 'paramTypes'
причем даже без использования MsgT.
а вот такое
template<class Func>
void g(Func f) {
typedef typename boost::function_types::parameter_types<decltype(&Func::operator())>::type paramTypes;
typedef typename boost::mpl::at<paramTypes, boost::mpl::int_<1> >::type Arg0;
}
вполне успешно компилируется.
Это у меня msvc слишком древний? Или есть какой-то криминал?
спасибо!