http://d.puremagic.com/issues/show_bug.cgi?id=10981
Summary: Contracts in pure class methods are useless
Product: D
Version: D2
Platform: All
OS/Version: All
Status: NEW
Severity: regression
Priority: P2
Component: DMD
AssignedTo: [email protected]
ReportedBy: [email protected]
--- Comment #0 from Henning Pohl <[email protected]> 2013-09-06 11:29:40
PDT ---
This regression was my fault, sorry for that:
https://github.com/D-Programming-Language/dmd/pull/2516
I can't believe it passed the test suite:
class C
{
void foo(int i) pure
in { assert(i); }
body { }
}
---
main.d(4): Error: pure nested function '__require' cannot access mutable data
'i'
---
--
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------