[Issue 10724] New: Allow slice of string literal to convert to const(char)*
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Sat Jul 27 23:46:28 PDT 2013
http://d.puremagic.com/issues/show_bug.cgi?id=10724
Summary: Allow slice of string literal to convert to
const(char)*
Product: D
Version: D2
Platform: All
OS/Version: All
Status: NEW
Severity: enhancement
Priority: P2
Component: DMD
AssignedTo: nobody at puremagic.com
ReportedBy: yebblies at gmail.com
--- Comment #0 from yebblies <yebblies at gmail.com> 2013-07-28 16:46:27 EST ---
The following code is perfectly safe because the slice happens at compile time,
but the conversion is not allowed.
void main()
{
const(char)* s = "abc"[0..$-1];
}
--
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
More information about the Digitalmars-d-bugs
mailing list