Skip to content

Commit 6c476f6

Browse files
committed
update to_ref test to use Eigen::all instead of Eigen::placeholders::all
1 parent cbb74b3 commit 6c476f6

1 file changed

Lines changed: 5 additions & 5 deletions

File tree

test/unit/math/prim/fun/to_ref_test.cpp

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ TEST(MathMatrix, to_ref_matrix_exprs_tuple) {
2525
TEST(MathMatrix, to_ref_matrix_views_tuple) {
2626
Eigen::MatrixXd a = Eigen::MatrixXd::Random(3, 3);
2727
auto x = std::make_tuple(a.block(0, 0, 1, 1),
28-
a(Eigen::placeholders::all, std::vector{2, 1, 1}),
28+
a(Eigen::all, std::vector{2, 1, 1}),
2929
a.array());
3030
auto x_ref = stan::math::to_ref(x);
3131
using x_ref_t = decltype(x_ref);
@@ -47,10 +47,10 @@ TEST(MathMatrix, to_ref_matrix_views_exprs_tuple) {
4747
auto x = std::make_tuple(
4848
a.block(0, 0, 1, 1),
4949
std::make_tuple(a.block(0, 0, 1, 1),
50-
a(Eigen::placeholders::all, std::vector{2, 1, 1}),
50+
a(Eigen::all, std::vector{2, 1, 1}),
5151
a.array()),
5252
std::make_tuple(a * a, a, a.array() * 3),
53-
a(Eigen::placeholders::all, std::vector{2, 1, 1}), a.array() * a.array());
53+
a(Eigen::all, std::vector{2, 1, 1}), a.array() * a.array());
5454
auto x_ref = stan::math::to_ref(x);
5555
using x_ref_t = decltype(x_ref);
5656
using stan::test::is_same_tuple_element_v;
@@ -99,11 +99,11 @@ TEST(MathMatrix, to_ref_matrix_views_exprs_moves_tuple) {
9999
a.block(0, 0, 1, 1),
100100
std::forward_as_tuple(
101101
a.block(0, 0, 1, 1),
102-
a(Eigen::placeholders::all,
102+
a(Eigen::all,
103103
std::vector{Eigen::Index{2}, Eigen::Index{1}, Eigen::Index{1}}),
104104
a.array()),
105105
std::forward_as_tuple(a * a, a, a.array() * 3),
106-
a(Eigen::placeholders::all,
106+
a(Eigen::all,
107107
std::vector{Eigen::Index{2}, Eigen::Index{1}, Eigen::Index{1}}),
108108
a.array() * a.array()));
109109
using x_ref_t = decltype(x_ref);

0 commit comments

Comments
 (0)