The following program compiles fine but is killed at runtime, as it tries to jump to an invalid instruction address:
```
enum E : void function()
{
First = () {} // `= function() {}` works
}
void main()
{
E.First(); // invalid jump
}
```
run.dlang.io Linux x64 asm:
_Dmain:
push RBP
mov RBP,RSP
mov RCX,pure nothrow @nogc @safe void onlineapp.E.__lambda2()@GOTPCREL[RIP]
xor EAX,EAX // btw, why 32-bit only?
call RAX
xor EAX,EAX
pop RBP
ret
Comment #1 by robert.schadek — 2024-12-13T19:06:49Z