blob: 8844ed0e9414f0b81a495814d575abf4d078c667 [file] [log] [blame]
// REQUIRED_ARGS: -checkaction=context -preview=dip1000
// Issue 22919 - [dip1000] -checkaction=context gives "assigned to `__assertOp2` with longer lifetime" (
// https://issues.dlang.org/show_bug.cgi?id=22919
@safe:
struct S
{
int* p;
ref S get() scope return {return this;}
}
void main()
{
scope S arr = S();
assert(arr == arr.get());
}