id,summary,reporter,owner,description,type,status,milestone,component,version,severity,resolution,keywords,cc 1469,[mpl] nested typedef of set has two different meanings,sven.vanechelpoel@…,Aleksey Gurtovoy,"This problem was diagnosed by Steve Watanabe after my posting on the developer list (see http://thread.gmane.org/gmane.comp.lib.boost.devel/168339/focus=168366) Basically the following doesn't compile: {{{ #include #include #include #include #include using namespace boost::mpl; template< typename T > > struct as_set : copy< T , inserter< set<> , insert< _1, _2 > > > {}; typedef set a_set; typedef vector a_vector; typedef as_set< a_set >::type set_as_set; typedef as_set< a_vector >::type vector_as_set; typedef next< begin< a_set >::type >::type THIS_IS_OK; typedef next< next< begin< a_set >::type >::type >::type THIS_IS_OK_AS_WELL; typedef next< begin< a_vector >::type >::type THIS_IS_OK_TOO; typedef next< begin< set_as_set >::type >::type THIS_WORKS_TOO; typedef next< next< begin< set_as_set >::type >::type >::type THIS_FAILS; typedef next< next< begin< vector_as_set >::type >::type >::type THIS_FAILS_TOO; }}} Steve Watanabe diagnosed this to be a problem of mpl::set using the nested typedef 'type' for two different purposes: one as an alias of the set<>, the other refering to the item type. The result is that upon iteration the termination condition isn't recognized and the iterator blows up",Bugs,new,To Be Determined,mpl,Boost 1.34.1,Problem,,,