https://issues.dlang.org/show_bug.cgi?id=7492

--- Comment #8 from Denis Shelomovskij <[email protected]> ---
(In reply to Kenji Hara from comment #7)
> (In reply to Denis Shelomovskij from comment #5)
> > Filed issue 14017.
> ...
> Anyway, at least it's an inconsistent compiler behavior. I reopen this.

Issue 14017 is about this inconsistent behavior.

Also we both changed our positions. I see no reasonable profit from
"effectively `pure`" CTFE-able functions and worst of all such feature will
introduce unpleasant inconsistency:
---
int[] f() { return new int[1];  }

void main()
{
    // With effectively `pure` feature:
    static immutable s = f(); // OK
    immutable s = f(); // error
}
---

So I'm for marking this one as INVALID and for fixing Issue 14017.

--

Reply via email to