How to move append to an array?

Yuxuan Shui via Digitalmars-d-learn digitalmars-d-learn at puremagic.com
Mon May 15 14:38:52 PDT 2017


Suppose I have a

struct A {
   @disable this(this);
} x;

How do I append it into an array?

Do I have to do

array.length++;
moveEmplace(x, array[$-1]);

?


More information about the Digitalmars-d-learn mailing list