[Issue 9258] New: opAssign with base class triggers "identity assignment operator overload" error
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Wed Jan 2 11:16:23 PST 2013
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: nobody at puremagic.com
ReportedBy: siegelords_abode at yahoo.com
--- Comment #0 from siegelords_abode at yahoo.com 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: -------
More information about the Digitalmars-d-bugs
mailing list