http://d.puremagic.com/issues/show_bug.cgi?id=9869
Summary: invariant problem in template Class
Product: D
Version: D2
Platform: x86_64
OS/Version: Linux
Status: NEW
Severity: normal
Priority: P2
Component: DMD
AssignedTo: [email protected]
ReportedBy: [email protected]
--- Comment #0 from cbr <[email protected]> 2013-04-03 12:59:20 PDT ---
Created an attachment (id=1205)
this show the invariant problem
The code example below is a cut down version of a larger code.
The code was written for in D1 and is now converted to D2.
In D1 the invariant test passed but in D2 it does not DMD 2.060 2.061 2.062.
The problem occurs in the this() member of Plane.
In line 293 of test_painter.d the pl_bottom private member function is
initialized and it fails in the invariant line 336.
A debugger (gdb) show that the invariant function is called even when a private
member is initialized.
Maybe invariant function has changed meaning in D2 but then I don't know how to
use invariant in D2.
I have tried to put the private keyword in front of the invariant but it
doesn't seem to have any effect on the invariant.
I except that invariant is like unittest so they a kind of private
Thank you for the good work you are doing.
--
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------