2011-07-27から1日間の記事一覧

C++0x で関数ポインタ型を定義

alias declaration(Template Aliases) が実装されていれば using を使用して、わかりやすく関数ポインタ型を定義できるので試してみたました。 [ソース] #include <boost/mpl/assert.hpp> #include <boost/type_traits/is_same.hpp> #include <iostream> using func_type = int(*)(int, int); // typedef int(*func_type)(int</iostream></boost/type_traits/is_same.hpp></boost/mpl/assert.hpp>…