include
eigenpy
utils
scalar-name.hpp
Go to the documentation of this file.
1
/*
2
* Copyright 2020 INRIA
3
*/
4
5
#ifndef __eigenpy_utils_scalar_name_hpp__
6
#define __eigenpy_utils_scalar_name_hpp__
7
8
#include <complex>
9
#include <string>
10
11
namespace
eigenpy
{
12
template
<
typename
Scalar>
13
struct
scalar_name
{
14
static
std::string
shortname
();
15
};
16
17
template
<>
18
struct
scalar_name
<float> {
19
static
std::string
shortname
() {
return
"f"
; };
20
};
21
22
template
<>
23
struct
scalar_name
<double> {
24
static
std::string
shortname
() {
return
"d"
; };
25
};
26
27
template
<>
28
struct
scalar_name
<long double> {
29
static
std::string
shortname
() {
return
"ld"
; };
30
};
31
32
template
<
typename
Scalar>
33
struct
scalar_name
<std::complex<Scalar> > {
34
static
std::string
shortname
() {
return
"c"
+
scalar_name<Scalar>
(); };
35
};
36
}
// namespace eigenpy
37
38
#endif // ifndef __eigenpy_utils_scalar_name_hpp__
eigenpy::scalar_name
Definition:
scalar-name.hpp:13
eigenpy::scalar_name< long double >::shortname
static std::string shortname()
Definition:
scalar-name.hpp:29
eigenpy
Definition:
alignment.hpp:14
eigenpy::scalar_name::shortname
static std::string shortname()
eigenpy::scalar_name< float >::shortname
static std::string shortname()
Definition:
scalar-name.hpp:19
eigenpy::scalar_name< double >::shortname
static std::string shortname()
Definition:
scalar-name.hpp:24
eigenpy::scalar_name< std::complex< Scalar > >::shortname
static std::string shortname()
Definition:
scalar-name.hpp:34
eigenpy
Author(s): Justin Carpentier, Nicolas Mansard
autogenerated on Fri Jun 2 2023 02:10:26