Developer documentation

texp_container_traits.hpp
Go to the documentation of this file.
1 #ifndef realroot_CONTAINER_TRAITS_H
2 #define realroot_CONTAINER_TRAITS_H
3 
4 namespace mmx {
5 
6 namespace texp
7 {
8  template < class R, class X >
9  struct instanceof { typedef null_t T; };
10  template < template<class> class R, class X, class Y>
11  struct instanceof< R<X>, Y > { typedef R<Y> T; };
12  template< template<class,int> class R, int N, class X, class Y>
13  struct instanceof< R<X,N>, Y> { typedef R<Y,N> T; };
14  template< template<class,unsigned> class R, unsigned N, class X, class Y>
15 
16  struct instanceof< R<X,N>, Y> { typedef R<Y,N> T; };
17  // synaps view
18  template< template<class,class> class V, class C, class R, class Y>
19  struct instanceof< V<C,R>, Y > { typedef V<Y, typename instanceof<R,Y>::T > T; };
20 
21  template < class A, class B >
22  struct sup_container { typedef A T; };
23 
24  template < class Container >
25  struct value_type_{ typedef typename Container::value_type T; };
26  template< template<class X> class R, class X >
27  struct value_type_< R<X> > { typedef X T; };
28  template< typename C, unsigned N > struct value_type_< C[N] > { typedef C T; };
29  template< typename C > struct value_type_<C*> { typedef C T; };
30  template< typename C > struct value_type_<const C*> { typedef C T; };
31  template < class Container >
33 };
34 
35 }// end namespace mmx
36 
37 #endif
V< Y, typename instanceof< R, Y >::T > T
Definition: texp_container_traits.hpp:19
null_t T
Definition: texp_container_traits.hpp:9
Container::value_type T
Definition: texp_container_traits.hpp:25
TMPL X
Definition: polynomial_operators.hpp:148
structure defining a the empty list
Definition: texp_bool.hpp:11
C T
Definition: texp_container_traits.hpp:29
A T
Definition: texp_container_traits.hpp:22
TMPL int N(const MONOMIAL &v)
Definition: monomial_glue.hpp:60
C T
Definition: texp_container_traits.hpp:30
X T
Definition: texp_container_traits.hpp:27
Definition: texp_container_traits.hpp:22
value_type_< typename ucstref< Container >::T >::T T
Definition: texp_container_traits.hpp:32
R< Y, N > T
Definition: texp_container_traits.hpp:13
Definition: texp_container_traits.hpp:25
Definition: texp_container_traits.hpp:32
double C
Definition: solver_mv_fatarcs.cpp:16
R< Y > T
Definition: texp_container_traits.hpp:11
C T
Definition: texp_container_traits.hpp:28
Definition: array.hpp:12
Definition: texp_container_traits.hpp:9
Home