http://d.puremagic.com/issues/show_bug.cgi?id=9258
Summary: opAssign with base class triggers "identity assignment
operator overload" error
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 [email protected] 2013-01-02 11:16:22 PST ---
This code worked fine on 2.060, but is broken on 2.061:
class B { }
class A : B // test.d(3): Error: class test.A identity assignment operator
overload is illegal
{
void opAssign(B b)
{
}
}
Firstly, the error line is wrong. Secondly, the assignment is not an identity
assignment, as this, without the overload, does not compile:
A a;
B b;
a = b;
I interpret identity assignment to mean strictly assignment of one type to the
same type.
--
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------