https://d.puremagic.com/issues/show_bug.cgi?id=12422
Summary: Templated nested function is inferred as `pure` even
if it calls impure functions
Product: D
Version: D2
Platform: All
OS/Version: All
Status: NEW
Keywords: accepts-invalid
Severity: normal
Priority: P2
Component: DMD
AssignedTo: [email protected]
ReportedBy: [email protected]
--- Comment #0 from Denis Shelomovskij <[email protected]> 2014-03-20
14:51:06 MSK ---
This code shouldn't compile:
---
int i;
void f() { ++i; }
void main() pure
{
void g()() { f(); }
g();
}
---
--
Configure issuemail: https://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------