Possible bugs (dangling references) due to returning reference to temporary object in l1_proximal.h?
Opened this issue · 0 comments
krishnakumarg1984 commented
In l1_proximal.h
, we have
Vector<Real> const &weights() const { return L1TightFrame<Scalar>::weights(); }
LinearTransform<Vector<Scalar>> const &Psi() const { return L1TightFrame<Scalar>::Psi(); }
Can we please have a closer look at this (first visually, and then maybe through unit tests)? This was flagged in static analysis that there functions are likely returning references to temporary objects (i.e. dangling references).