mirror of
https://gitlab.com/libeigen/eigen.git
synced 2025-09-15 10:53:50 +08:00
bug #1451: fix numeric_limits<AutoDiffScalar<Der>> with a reference as derivative type
This commit is contained in:
parent
7f8b53fd0e
commit
09c81ac033
@ -684,10 +684,15 @@ template<typename DerType> struct NumTraits<AutoDiffScalar<DerType> >
|
|||||||
}
|
}
|
||||||
|
|
||||||
namespace std {
|
namespace std {
|
||||||
|
|
||||||
template <typename T>
|
template <typename T>
|
||||||
class numeric_limits<Eigen::AutoDiffScalar<T> >
|
class numeric_limits<Eigen::AutoDiffScalar<T> >
|
||||||
: public numeric_limits<typename T::Scalar> {};
|
: public numeric_limits<typename T::Scalar> {};
|
||||||
|
|
||||||
|
template <typename T>
|
||||||
|
class numeric_limits<Eigen::AutoDiffScalar<T&> >
|
||||||
|
: public numeric_limits<typename T::Scalar> {};
|
||||||
|
|
||||||
} // namespace std
|
} // namespace std
|
||||||
|
|
||||||
#endif // EIGEN_AUTODIFF_SCALAR_H
|
#endif // EIGEN_AUTODIFF_SCALAR_H
|
||||||
|
Loading…
x
Reference in New Issue
Block a user