
Russell Hind wrote:
I now get an error on line 311 of foreach.hpp which is in
template<typename T> struct is_range_base { BOOST_STATIC_CONSTANT(size_t, size = sizeof(boost::foreach::is_range_fun((T*)0))); BOOST_STATIC_CONSTANT(bool, value = sizeof(yes_type)==size); typedef mpl::bool_<value> type; };
The error is on the typedef mpl::bool_<value> type line. (with and without the #defines in).
[C++ Error] foreach.hpp(311): E2231 Member is_range_base<T>::value cannot be used without an object [C++ Error] foreach.hpp(311): E2299 Cannot generate template specialization from 'mpl::bool_<C_>' [C++ Error] foreach.hpp(311): E2040 Declaration terminated incorrectly
I'm afraid you're out of luck, for now. Without access to this compiler, or knowledge of it's quirks, there's nothing I can do. I'll gladly accept a patch if you can make it work. The first thing I would try if I were you would be to change the line: typedef mpl::bool_<value> type; to typedef mpl::bool_<is_range_base<T>::value> type; That's all I can think of right now. -- Eric Niebler Boost Consulting www.boost-consulting.com