id summary reporter owner description type status milestone component version severity resolution keywords cc 1468 [typeof] Problems with VC8/VC9 when using code analysis Richard Webb Peder Holt "Enabling the Code Analysis option in VC8SP1 and VC9 causes native typeof to fail. For example, the code: {{{ BOOST_AUTO(tmp, std::make_pair(1, 2)); }}} results in the error: {{{ E:\Development\BoostSVN\boost/typeof/msvc/typeof_impl.hpp(172) : error C2975: 'ref_type_info' : invalid template argument for 'boost::type_of::msvc_typeid_wrapper', expected compile-time constant expression 1> E:\Development\BoostSVN\boost/typeof/msvc/typeof_impl.hpp(174) : see reference to class template instantiation 'boost::type_of::encode_type' being compiled 1>E:\Development\BoostSVN\boost/typeof/msvc/typeof_impl.hpp(172) : error C2440: 'specialization' : cannot convert from 'int' to 'const type_info &' 1>E:\Development\BoostSVN\boost/typeof/msvc/typeof_impl.hpp(172) : error C2975: 'ref_type_info' : invalid template argument for 'boost::type_of::msvc_typeid_wrapper', expected compile-time constant expression 1> .\Stuff.cpp(19) : see reference to class template instantiation 'boost::type_of::encode_type' being compiled 1> with 1> [ 1> T=std::pair 1> ] 1>E:\Development\BoostSVN\boost/typeof/msvc/typeof_impl.hpp(172) : error C2440: 'specialization' : cannot convert from 'int' to 'const type_info &' 1>.\Stuff.cpp(19) : error C2975: 'ref_type_info' : invalid template argument for 'boost::type_of::msvc_typeid_wrapper', expected compile-time constant expression 1>.\Stuff.cpp(19) : error C2440: 'specialization' : cannot convert from 'int' to 'const type_info &' 1>.\Stuff.cpp(19) : error C2440: 'specialization' : cannot convert from 'int' to 'const type_info &' 1> .\Stuff.cpp(19) : see reference to class template instantiation 'boost::type_of::msvc_typeid_wrapper' being compiled 1> with 1> [ 1> ref_type_info=0x0 1> ] 1>.\Stuff.cpp(19) : error C2973: 'boost::type_of::msvc_typeid_wrapper' : invalid template argument 'int' }}} Everything is ok when analysis is disabled. I've previously been using a Boost1.34.1 patched with the first version of typeof with VC8 native support, and that works ok in either case. Looking through the change history, it seems to have started failing at revision 38801." Bugs closed Boost 1.35.0 typeof Boost Development Trunk Problem fixed