Comment #0 by snarwin+bugzilla — 2021-01-11T20:03:14Z
The following example program fails to compile as of DMD 2.094.2:
---
import core.lifetime: move;
struct NoCopy { @disable this(this); }
NoCopy fun(NoCopy x)
{
return move(x);
}
enum y = fun(NoCopy());
---
The compiler produces the following error:
---
/usr/include/dmd/druntime/import/core/lifetime.d(1804): Error: memcpy cannot be interpreted at compile time, because it has no available source code
---
This issue is related to, but distinct from, issue 8991--that issue is a DMD bug, whereas this one is a Druntime bug.
Comment #1 by robert.schadek — 2024-12-07T13:40:54Z