realroot_doc 0.1.1
/Users/mourrain/Devel/mmx/realroot/include/realroot/texp_kernelof.hpp
Go to the documentation of this file.
00001 #ifndef realroot_ARITHM_TRAITS_KERNELOF_H
00002 #define realroot_ARITHM_TRAITS_KERNELOF_H
00003 #include <realroot/texp.hpp>
00004 
00005 namespace mmx {
00006 
00007 template<class K> struct algebraic;
00008 
00009 namespace texp {
00010 
00011   using namespace texp;
00012 
00013   template<class mplib, typename _ieee_ = double >
00014   struct kernel
00015     {
00016       typedef typename mplib::integer  integer;
00017       typedef typename mplib::rational rational;
00018       typedef typename mplib::floating floating;
00019       typedef _ieee_                   ieee;
00020     };
00021   
00023   template<class X>
00024   struct kernelof_ { typedef null_t T; };
00025   template<class K>
00026   struct kernelof_< algebraic<K> > { typedef K T; };
00027 
00029   template<class X>
00030   struct kernelof { typedef typename kernelof_< typename ucstref<X>::T >::T T; };
00032   template<class X>
00033   struct haskernel { typedef typename tnot< typename equal< null_t, typename kernelof<X>::T >::T >::T T; };
00034   
00035 
00036 };
00037 
00038 }// end namespace mmx
00039 
00040 #endif