https://issues.dlang.org/show_bug.cgi?id=23551
Grim Maple <[email protected]> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |[email protected] --- Comment #3 from Grim Maple <[email protected]> --- (In reply to Dennis from comment #2) > What is the expected message? The error itself targets this line ``` auto b = x[0..1]; ``` which isn't what causes the issue. It's this line ``` enum x = [1,4]; ``` which prevents slicing from being @nogc compatible. If changed to static immutable x = [1,4]; code compiles fine --
