DIP1000: The return of 'Extend Return Scope Semantics'

Dennis dkorpel at gmail.com
Fri Jun 11 10:27:19 UTC 2021


On Friday, 11 June 2021 at 03:12:29 UTC, Walter Bright wrote:
> Hence a simple solution:
>
> Make move() @trusted.

I don't think that makes sense. `move` is `@safe` anyway for 
non-scope inputs, and for scope inputs you wouldn't want it to 
lie about its interface (pretending it's `scope` when it isn't). 
Also you don't want it to call a `@system` move constructor in 
`@safe` code.

> Write an @safe alternative to move() with the parameters 
> swapped.

What would that alternative be called?



More information about the Digitalmars-d mailing list