All Classes Namespaces Files Functions Variables Typedefs Enumerator Friends Macros
promote_scalar_type.hpp
Go to the documentation of this file.
#ifndef STAN_MATH_PRIM_SCAL_FUN_PROMOTE_SCALAR_TYPE_HPP
#define STAN_MATH_PRIM_SCAL_FUN_PROMOTE_SCALAR_TYPE_HPP
#include <vector>
namespace stan {
namespace math {
template <typename T, typename S>
struct promote_scalar_type {
typedef T type;
};
template <typename T, typename S>
struct promote_scalar_type<T, std::vector<S> > {
typedef std::vector<typename promote_scalar_type<T, S>::type> type;
};
}
}
#endif
stan::math::promote_scalar_type
Template metaprogram to calculate a type for converting a convertible type.
Definition: promote_scalar_type.hpp:19
stan::math::promote_scalar_type::type
T type
The promoted type.
Definition: promote_scalar_type.hpp:23
stan::math::promote_scalar_type< T, std::vector< S > >::type
std::vector< typename promote_scalar_type< T, S >::type > type
The promoted type.
Definition: promote_scalar_type.hpp:40

[ Stan Home Page ] © 2011–2015, Stan Development Team.