1#ifndef STAN_MATH_REV_FUN_ADJOINT_OF_HPP
2#define STAN_MATH_REV_FUN_ADJOINT_OF_HPP
17 throw std::runtime_error(
18 "internal::nonexisting_adjoint::operator+= should never be called! "
19 "Please file a bug report. rev/fun/adjoint_of.hpp line "
20 + std::to_string(__LINE__));
24 throw std::runtime_error(
25 "internal::nonexisting_adjoint::operator-= should never be called! "
26 "Please file a bug report. rev/fun/adjoint_of.hpp line "
27 + std::to_string(__LINE__));
38template <
typename T, require_var_t<T>* =
nullptr>
51template <
typename T, require_not_var_t<T>* =
nullptr>
auto & adjoint_of(const T &x) noexcept
Returns a reference to a variable's adjoint.
The lgamma implementation in stan-math is based on either the reentrant safe lgamma_r implementation ...
nonexisting_adjoint operator+(const T &)
nonexisting_adjoint operator-=(T) const
nonexisting_adjoint operator+=(T) const