ALPSCore reference
scalar.hpp
Go to the documentation of this file.
1 /*
2  * Copyright (C) 1998-2018 ALPS Collaboration. See COPYRIGHT.TXT
3  * All rights reserved. Use is subject to license terms. See LICENSE.TXT
4  * For use in publications, see ACKNOWLEDGE.TXT
5  */
6 
13 #ifndef ALPS_NUMERIC_SCALAR_HPP_1444d6233fe94fe1ba881085afd0f012
14 #define ALPS_NUMERIC_SCALAR_HPP_1444d6233fe94fe1ba881085afd0f012
15 
16 #include <complex>
18 
19 namespace alps {
20  namespace numeric {
22 
27  template <typename T>
28  struct scalar : public alps::element_type<T> {};
29 
31  template <typename T>
32  struct scalar< std::complex<T> > {
33  typedef std::complex<T> type;
34  };
35  }
36 }
37 
38 #endif /* ALPS_NUMERIC_SCALAR_HPP_1444d6233fe94fe1ba881085afd0f012 */
STL namespace.
Metafunction returning "mathematical scalar" type for type T.
Definition: scalar.hpp:28