Skip to content

Commit 4cb2e8c

Browse files
committed
Merge commit 'b82d68ced2e73c8188f3bbf287c1321033103986' into HEAD
2 parents f8c103a + b82d68c commit 4cb2e8c

2 files changed

Lines changed: 9 additions & 7 deletions

File tree

.github/workflows/main.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -71,7 +71,7 @@ jobs:
7171
python runTests.py -j4 ${{ matrix.config.tests }}
7272
7373
- name: Upload gtest_output xml
74-
uses: actions/upload-artifact@v4
74+
uses: actions/upload-artifact@v5
7575
if: failure()
7676
with:
7777
name: gtest_outputs_xml
@@ -134,7 +134,7 @@ jobs:
134134
python runTests.py -j2 $MixFunProbTestsArray[(${{ matrix.group }} - 1)]
135135
136136
- name: Upload gtest_output xml
137-
uses: actions/upload-artifact@v4
137+
uses: actions/upload-artifact@v5
138138
if: failure()
139139
with:
140140
name: gtest_outputs_xml

stan/math/prim/err/validate_positive_index.hpp

Lines changed: 7 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -10,19 +10,21 @@ namespace stan {
1010
namespace math {
1111

1212
/**
13-
* Check that simplex is at least size 1
13+
* Check that size is at least 1. Used for simplexes and
14+
* other constraints that do a (size - 1) operation.
1415
*
15-
* @param var_name Name of simplex variable
16+
* @param var_name Name of variable
1617
* @param expr Expression in which variable is declared
17-
* @param val Size of simplex
18-
* @throw std::invalid_argument if simplex size is less than 1
18+
* @param val Size to check
19+
* @throw std::invalid_argument if size is less than 1
1920
*/
2021
inline void validate_positive_index(const char* var_name, const char* expr,
2122
int val) {
2223
if (val < 1) {
2324
[&]() STAN_COLD_PATH {
2425
std::stringstream msg;
25-
msg << "Found dimension size less than one in simplex declaration"
26+
msg << "Found dimension size less than one in constrained type "
27+
"declaration (simplex, sum_to_zero_vector, etc.)"
2628
<< "; variable=" << var_name << "; dimension size expression=" << expr
2729
<< "; expression value=" << val;
2830
std::string msg_str(msg.str());

0 commit comments

Comments
 (0)