Closed jacobly0 closed 2 years ago
Thanks for your PR.
The comma expression is/was used for C++11 constexpr-ness.
Correctness comes first naturally.
Have to think a bit what approach I'd like.
That's what I get for not checking clang warnings. Since l-value refs aren't affected, the simplest solution is to just rearrange the expression.
Returning an r-value reference through the comma operator is miscompiled by MSVC v19.22, as evidenced here.
Examples of tests failures without the
expected.hpp
changes on MSVC v19.16: