mirror of
https://github.com/dlang/dmd.git
synced 2025-04-26 05:00:16 +03:00
20 lines
303 B
D
20 lines
303 B
D
/*
|
|
TEST_OUTPUT:
|
|
---
|
|
fail_compilation/fail18994.d(19): Error: struct `fail18994.Type1` is not copyable because it has a disabled postblit
|
|
---
|
|
*/
|
|
struct Type2
|
|
{
|
|
int opApply(int delegate(ref Type1)) { return 0; }
|
|
}
|
|
|
|
struct Type1
|
|
{
|
|
@disable this(this);
|
|
}
|
|
|
|
void test()
|
|
{
|
|
foreach(b; Type2()) {}
|
|
}
|