mirror of
https://github.com/dlang/dmd.git
synced 2025-04-26 05:00:16 +03:00
14 lines
242 B
D
14 lines
242 B
D
// https://issues.dlang.org/show_bug.cgi?id=19415
|
|
|
|
struct S
|
|
{
|
|
int x;
|
|
S foo() return { return S(x); }
|
|
this(this) @disable;
|
|
}
|
|
|
|
S bar()
|
|
{
|
|
S s;
|
|
return s; // Error: struct `S` is not copyable because it is annotated with @disable
|
|
}
|