On Thursday, 14 October 2021 at 17:37:21 UTC, Paul Backus wrote:
On Thursday, 14 October 2021 at 16:53:17 UTC, Kostiantyn Tokar
wrote:
[...]
Poor test coverage. If you go through Phobos and test
everything with a non-copyable struct (`@disable this(this)`),
you will find that most templates (including `Tuple`) fail to
compile. It is simply a case that the authors of the code never
considered.
[...]
I suspect it is neglected because nobody wants to volunteer for
the tedious work of going through Phobos, adding unit tests
that check for unnecessary copies, and inserting `auto ref` and
`forward` in the appropriate places.
Maybe DIP 1040 will automatically solve that?
last use of objects that is a copy gets elided into a move
That is what it states, so maybe this one time, the problem will
go away just by waiting?