On Wednesday, 22 January 2014 at 12:11:22 UTC, Casper Færgemand wrote:
import std.algorithm;
import std.concurrency;

void main() {
        Tid[] tids = [];
        Tid tid = thisTid;
        tids ~= tid;
        tids.remove(tid);
}

Why does this not compile?

Because "remove" takes an "offset" as an argument, not an element.

To remove an element, I *think* you do it this way:

tids = tids.remove!(a=>a == tid)();

Reply via email to