Closed wolfv closed 7 years ago
Confirmed
@JohanMabille, any clue?
I can't test it now but it looks like the generated move constructor of xview (called when building the xfunction for operator+) tries to move the m_e member of the moved xview, making it appear as an rvalue.
I confirm that doing auto v = xt::view(arr1, 1)
and passing it to the next line work.
Yes that is it. We need to implement move constructors for expressions holding closures, which only move held closures when they are value types.
After further investigations, the problem comes from the xview constructor, which is called with no slice argument instead of the copy constructor. Adding a template parameter before the template parameter pack fixes the problem.
Failes to compile on ubuntu 16.04 with g++5.4 with
Maybe someone else can confirm?