mirror of
https://github.com/dlang/dmd.git
synced 2025-04-26 05:00:16 +03:00
28 lines
303 B
D
28 lines
303 B
D
shared struct Shared
|
|
{
|
|
static Shared make()
|
|
{
|
|
return Shared();
|
|
}
|
|
|
|
~this()
|
|
{
|
|
}
|
|
}
|
|
|
|
shared struct Foo
|
|
{
|
|
~this()
|
|
{
|
|
}
|
|
}
|
|
|
|
struct Inner { ~this() {} }
|
|
struct Outer { shared(Inner) inner; }
|
|
|
|
void main()
|
|
{
|
|
Foo x = Foo();
|
|
auto s = Shared.make();
|
|
Outer _;
|
|
}
|