From b73e22905dd1544830b41463576d112c53fc66d9 Mon Sep 17 00:00:00 2001 From: Benoit Jacob Date: Thu, 18 Feb 2010 20:42:38 -0500 Subject: miserable half-working state, commiting to a fork just in case, just to perfect my day, my hard disk would die. Will write a more detailed commit message once it's working. --- Eigen/src/Core/ReturnByValue.h | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) (limited to 'Eigen/src/Core/ReturnByValue.h') diff --git a/Eigen/src/Core/ReturnByValue.h b/Eigen/src/Core/ReturnByValue.h index 920269365..8d45fc31b 100644 --- a/Eigen/src/Core/ReturnByValue.h +++ b/Eigen/src/Core/ReturnByValue.h @@ -34,14 +34,9 @@ struct ei_traits > : public ei_traits::ReturnMatrixType> { enum { - // FIXME had to remove the DirectAccessBit for usage like - // matrix.inverse().block(...) - // because the Block ctor with direct access - // wants to call coeffRef() to get an address, and that fails (infinite recursion) as ReturnByValue - // doesnt implement coeffRef(). - // The fact that I had to do that shows that when doing xpr.block() with a non-direct-access xpr, - // even if xpr has the EvalBeforeNestingBit, the block() doesn't use direct access on the evaluated - // xpr. + // We're disabling the DirectAccess because e.g. the constructor of + // the Block-with-DirectAccess expression requires to have a coeffRef method. + // Also, we don't want to have to implement the stride stuff. Flags = (ei_traits::ReturnMatrixType>::Flags | EvalBeforeNestingBit) & ~DirectAccessBit }; -- cgit v1.2.3