Return const data pointer from TensorRef evaluator.data()

This commit is contained in:
Eugene Zhulenev 2019-12-18 23:19:36 +00:00
parent ae07801dd8
commit 73e55525e5

View File

@ -408,7 +408,7 @@ struct TensorEvaluator<const TensorRef<Derived>, Device>
return m_ref.coeffRef(index);
}
EIGEN_DEVICE_FUNC Scalar* data() const { return m_ref.data(); }
EIGEN_DEVICE_FUNC const Scalar* data() const { return m_ref.data(); }
protected:
TensorRef<Derived> m_ref;