mirror of
https://github.com/dlang/dmd.git
synced 2025-04-26 05:00:16 +03:00
18 lines
303 B
D
18 lines
303 B
D
void test()
|
|
{
|
|
int a;
|
|
|
|
struct Field
|
|
{
|
|
this(this) { ++a; }
|
|
~this() { --a; }
|
|
}
|
|
|
|
struct S
|
|
{
|
|
Field field; // generates __fieldPostblit, __fieldDtor, and opAssign
|
|
}
|
|
|
|
static assert(__traits(isNested, Field));
|
|
static assert(!__traits(isNested, S));
|
|
}
|