Skip to content

Commit ba10d73

Browse files
committed
Merge commit '5c6a4dd7a814a60bd3ea766ab8701ea2234724b3' into HEAD
2 parents f1f65c3 + 5c6a4dd commit ba10d73

164 files changed

Lines changed: 913 additions & 733 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.github/FUNDING.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,2 @@
1+
github: stan-dev
2+
custom: https://mc-stan.org/support/

stan/math/fwd/functor.hpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
#ifndef STAN_MATH_FWD_FUNCTOR_HPP
22
#define STAN_MATH_FWD_FUNCTOR_HPP
33

4+
#include <stan/math/fwd/functor/apply_scalar_unary.hpp>
45
#include <stan/math/fwd/functor/gradient.hpp>
56
#include <stan/math/fwd/functor/hessian.hpp>
67
#include <stan/math/fwd/functor/jacobian.hpp>

stan/math/fwd/meta/apply_scalar_unary.hpp renamed to stan/math/fwd/functor/apply_scalar_unary.hpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
1-
#ifndef STAN_MATH_FWD_META_APPLY_SCALAR_UNARY_HPP
2-
#define STAN_MATH_FWD_META_APPLY_SCALAR_UNARY_HPP
1+
#ifndef STAN_MATH_FWD_FUNCTOR_APPLY_SCALAR_UNARY_HPP
2+
#define STAN_MATH_FWD_FUNCTOR_APPLY_SCALAR_UNARY_HPP
33

4-
#include <stan/math/prim/meta/apply_scalar_unary.hpp>
4+
#include <stan/math/prim/functor/apply_scalar_unary.hpp>
55
#include <stan/math/fwd/core/fvar.hpp>
66

77
namespace stan {

stan/math/fwd/meta.hpp

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
#ifndef STAN_MATH_FWD_META_HPP
22
#define STAN_MATH_FWD_META_HPP
33

4-
#include <stan/math/fwd/meta/apply_scalar_unary.hpp>
54
#include <stan/math/fwd/meta/is_fvar.hpp>
65
#include <stan/math/fwd/meta/partials_type.hpp>
76
#include <stan/math/fwd/meta/operands_and_partials.hpp>

stan/math/prim/eigen_plugins.h

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -53,14 +53,14 @@ struct val_Op{
5353
//Returns value from a vari*
5454
template<typename T = Scalar>
5555
EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE
56-
std::enable_if_t<std::is_pointer<T>::value, reverse_return_t<T>>
56+
std::enable_if_t<std::is_pointer<T>::value, const double&>
5757
operator()(T &v) const { return v->val_; }
5858

5959
//Returns value from a var
6060
template<typename T = Scalar>
6161
EIGEN_DEVICE_FUNC EIGEN_STRONG_INLINE
6262
std::enable_if_t<(!std::is_pointer<T>::value && !is_fvar<T>::value
63-
&& !std::is_arithmetic<T>::value), reverse_return_t<T>>
63+
&& !std::is_arithmetic<T>::value), const double&>
6464
operator()(T &v) const { return v.vi_->val_; }
6565

6666
//Returns value from an fvar

stan/math/prim/fun/Phi.hpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -7,6 +7,7 @@
77
#include <stan/math/prim/fun/erf.hpp>
88
#include <stan/math/prim/fun/erfc.hpp>
99
#include <stan/math/prim/fun/Phi.hpp>
10+
#include <stan/math/prim/functor/apply_scalar_unary.hpp>
1011

1112
namespace stan {
1213
namespace math {

stan/math/prim/fun/Phi_approx.hpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33

44
#include <stan/math/prim/meta.hpp>
55
#include <stan/math/prim/fun/inv_logit.hpp>
6+
#include <stan/math/prim/functor/apply_scalar_unary.hpp>
67
#include <cmath>
78

89
namespace stan {

stan/math/prim/fun/acos.hpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,8 @@
1010
#include <stan/math/prim/fun/isfinite.hpp>
1111
#include <stan/math/prim/fun/isnan.hpp>
1212
#include <stan/math/prim/fun/polar.hpp>
13+
#include <stan/math/prim/functor/apply_scalar_unary.hpp>
14+
#include <stan/math/prim/functor/apply_vector_unary.hpp>
1315
#include <cmath>
1416
#include <complex>
1517

stan/math/prim/fun/acosh.hpp

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,7 @@
88
#include <stan/math/prim/fun/is_nan.hpp>
99
#include <stan/math/prim/fun/log.hpp>
1010
#include <stan/math/prim/fun/sqrt.hpp>
11+
#include <stan/math/prim/functor/apply_scalar_unary.hpp>
1112
#include <cmath>
1213
#include <complex>
1314

stan/math/prim/fun/asin.hpp

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,8 @@
88
#include <stan/math/prim/fun/Eigen.hpp>
99
#include <stan/math/prim/fun/i_times.hpp>
1010
#include <stan/math/prim/fun/value_of_rec.hpp>
11+
#include <stan/math/prim/functor/apply_scalar_unary.hpp>
12+
#include <stan/math/prim/functor/apply_vector_unary.hpp>
1113
#include <cmath>
1214
#include <complex>
1315

0 commit comments

Comments
 (0)