Merge pull request #7832 from WalterBright/chain-test

add test for Throwable.opApply()
merged-on-behalf-of: Mike Franklin <JinShil@users.noreply.github.com>
This commit is contained in:
The Dlang Bot 2018-02-20 12:38:22 +01:00 committed by GitHub
commit 7652a2bcee
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -379,6 +379,15 @@ void bug1513b()
assert(e.msg == "d");
assert(e.next.msg == "f");
assert(!e.next.next);
int i;
foreach (u; e)
{
if (i)
assert(u.msg == "f");
else
assert(u.msg == "d");
++i;
}
}
}