digitalmars.D.bugs - [Issue 7492] New: [CTFE] Error at assign to immutable character array
- d-bugmail puremagic.com (22/22) Feb 13 2012 http://d.puremagic.com/issues/show_bug.cgi?id=7492
- d-bugmail puremagic.com (14/14) Feb 23 2012 http://d.puremagic.com/issues/show_bug.cgi?id=7492
http://d.puremagic.com/issues/show_bug.cgi?id=7492 Summary: [CTFE] Error at assign to immutable character array Product: D Version: D2 Platform: All OS/Version: All Status: NEW Severity: normal Priority: P2 Component: DMD AssignedTo: nobody puremagic.com ReportedBy: verylonglogin.reg gmail.com --- Comment #0 from Denis <verylonglogin.reg gmail.com> 2012-02-13 14:55:15 MSK --- --- auto f() { return new char[1]; } immutable s = f(); // error, works with non-character arrays --- Error: cannot implicitly convert expression ("\xff") of type char[] to immutable(char[]) -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------
Feb 13 2012
http://d.puremagic.com/issues/show_bug.cgi?id=7492 Don <clugdbug yahoo.com.au> changed: What |Removed |Added ---------------------------------------------------------------------------- CC| |clugdbug yahoo.com.au --- Comment #1 from Don <clugdbug yahoo.com.au> 2012-02-23 02:06:22 PST --- I'm not sure about this. The int[] case may be an accepts-invalid bug. If you move the declaration of 's' into the inside of a function, you get the same error message, even though CTFE is not involved. And when you do that, if it's an int[] instead of char[], you get the same error. In any case the error is not generated by CTFE. -- Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email ------- You are receiving this mail because: -------
Feb 23 2012