https://issues.dlang.org/show_bug.cgi?id=14017
--- Comment #2 from Denis Shelomovskij <[email protected]> --- Note: This issue is created as a result of Issue 7492 discussion. (In reply to Steven Schveighoffer from comment #1) > It's CTFE executed, so immutable is fine. Although I think it would be > permissible for pure to be inferred here because of the auto return type. > > The bug is the opposite -- it should allow the char[] array to also be > assigned. It's not a bug, it's a current language type system rules. See enhancement Issue 14018 for language rules change request. And please, don't mix another language change request about purity inference because of `auto` return type in this issue. --
