Automatic Differentiation
 
Loading...
Searching...
No Matches
type_str.hpp
Go to the documentation of this file.
1#ifndef STAN_MATH_OPENCL_KERNEL_GENERATOR_TYPE_STR_HPP
2#define STAN_MATH_OPENCL_KERNEL_GENERATOR_TYPE_STR_HPP
3#ifdef STAN_OPENCL
4
5#include <string>
6
7namespace stan {
8namespace math {
13template <typename T>
14inline std::string type_str() {
15 static_assert(sizeof(T) == -1, "Unsupported type in type_str");
16 return "";
17}
18
19#define ADD_TYPE_TO_TYPE_STR(t) \
20 template <> \
21 inline std::string type_str<t>() { \
22 return #t; \
23 }
28#undef ADD_TYPE_TO_TYPE_STR
29} // namespace math
30} // namespace stan
31#endif
32#endif
std::string type_str()
Determines a string name of a type.
Definition type_str.hpp:14
The lgamma implementation in stan-math is based on either the reentrant safe lgamma_r implementation ...
Definition fvar.hpp:9
#define ADD_TYPE_TO_TYPE_STR(t)
Definition type_str.hpp:19