1 #ifndef STAN_MATH_PRIM_SCAL_ERR_CHECK_POSITIVE_SIZE_HPP
2 #define STAN_MATH_PRIM_SCAL_ERR_CHECK_POSITIVE_SIZE_HPP
28 std::stringstream msg;
29 msg <<
"; dimension size expression = " << expr;
30 std::string msg_str(msg.str());
32 "must have a positive size, but is ",
bool check_positive_size(const char *function, const char *name, const char *expr, const int size)
Return true if size is positive.
void invalid_argument(const char *function, const char *name, const T &y, const char *msg1, const char *msg2)
Throw an invalid_argument exception with a consistently formatted message.
int size(const std::vector< T > &x)