[Issue 8814] New: Issues casting opDispatch property when a write property exists
d-bugmail at puremagic.com
d-bugmail at puremagic.com
Sat Oct 13 12:46:50 PDT 2012
http://d.puremagic.com/issues/show_bug.cgi?id=8814
Summary: Issues casting opDispatch property when a write
property exists
Product: D
Version: D2
Platform: All
OS/Version: All
Status: NEW
Severity: normal
Priority: P2
Component: DMD
AssignedTo: nobody at puremagic.com
ReportedBy: siegelords_abode at yahoo.com
--- Comment #0 from siegelords_abode at yahoo.com 2012-10-13 12:46:48 PDT ---
DMDFE 2.059 and 2.060:
struct A
{
@property
int opDispatch(string s)()
{
return 1;
}
/* Works without error if the write property is removed */
@property
void opDispatch(string s)(int val)
{
}
}
void main()
{
auto a = A();
auto b = cast(int)a.test; // test.d(19): Error: cannot cast
a.opDispatch!("test")
}
--
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