[Issue 1972] New: Foreach range statement breaks CTFE
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Sat Apr 5 09:09:43 PDT 2008
http://d.puremagic.com/issues/show_bug.cgi?id=1972
Summary: Foreach range statement breaks CTFE
Product: D
Version: 2.012
Platform: PC
OS/Version: Windows
Status: NEW
Keywords: rejects-valid
Severity: normal
Priority: P2
Component: DMD
AssignedTo: bugzilla at digitalmars.com
ReportedBy: samukha at voliacable.com
----
int foo()
{
foreach (c; '0' .. '9')
{
}
return 0;
}
enum x = foo();
----
Error: cannot evaluate foo() at compile time
--
More information about the Digitalmars-d-bugs
mailing list