Fix compilation of stableNorm with some expressions as input

(grafted from 06bf1047f9
)
This commit is contained in:
Gael Guennebaud
2017-12-15 15:15:37 +01:00
parent bb28a2aada
commit 33b972d8b3
2 changed files with 11 additions and 1 deletions

View File

@@ -165,7 +165,7 @@ MatrixBase<Derived>::stableNorm() const
typedef typename internal::nested_eval<Derived,2>::type DerivedCopy;
typedef typename internal::remove_all<DerivedCopy>::type DerivedCopyClean;
DerivedCopy copy(derived());
const DerivedCopy copy(derived());
enum {
CanAlign = ( (int(DerivedCopyClean::Flags)&DirectAccessBit)