Blog post on automem

Atila Neves via Digitalmars-d-announce digitalmars-d-announce at puremagic.com
Fri Apr 28 15:25:09 PDT 2017


On Friday, 28 April 2017 at 22:06:57 UTC, Nordlöw wrote:
> On Friday, 28 April 2017 at 14:40:03 UTC, Mike Parker wrote:
>> Blog:
>> https://dlang.org/blog/2017/04/28/automem-hands-free-raii-for-d/
>
> Nice.
>
> One thing, Atila; what about replacing
>
>     typeof(u1) u2;
>     move(u1, u2);
>
> with
>
>     typeof(u1) u2 = move(u1);
>
> or, alternatively,
>
>     typeof(u1) u2 = u1.move;
>
> ?

I only learned about the single argument move when Manu did the 
other day in his thread! I just changed the code and the 
README.md to read like your last example.

Atila


More information about the Digitalmars-d-announce mailing list