2012-09-01から1ヶ月間の記事一覧

Boost.TypeErasure で多重定義の呼び出し

Boost.TypeErasure では any の Concept に複数のシグネチャを定義することで多重定義されているメンバ関数を呼び出すことが出来ます。 BOOST_TYPE_ERASURE_MEMBER を使用した場合はこんな感じです。 [ソース] #include <boost/type_erasure/any.hpp> #include <boost/type_erasure/member.hpp> #include <boost/mpl/vector.hpp> #include <type_traits> BOOS</type_traits></boost/mpl/vector.hpp></boost/type_erasure/member.hpp></boost/type_erasure/any.hpp>…