Closed ArsenArsen closed 2 years ago
In the case of T being an lvalue reference, collapsing rules result in a cast to std::remove_reference_t<T>&
, causing the reference to be copied. In all other cases, the resulting cast is to an rvalue reference.
I am not aware of any regressions, though my test cases were admittedly limited. I'm looking at expanding on a test suite to make it easier to know what's valid in the future.
EDIT: I remembered that a good test case is managarm/mlibc/libasync. libasync appears to fail to build with these changes. At least a relatively recent version builds now.
wait, this is nonsense