http://d.puremagic.com/issues/show_bug.cgi?id=9396
Summary: Wrong line number when assigning nested enum to struct
Product: D
Version: D2
Platform: All
OS/Version: All
Status: NEW
Keywords: diagnostic
Severity: normal
Priority: P2
Component: DMD
AssignedTo: [email protected]
ReportedBy: [email protected]
--- Comment #0 from Andrej Mitrovic <[email protected]> 2013-01-25
18:06:38 PST ---
This is invalid code, but the diagnostic error is on line 9 instead of line 14:
enum E
{
mem
}
struct S
{
E e;
enum mem = E.mem; // L9
}
void main()
{
S s = S.mem; // L14
}
$ test.d(9): Error: cannot implicitly convert expression (cast(E)0) of type E
to S
--
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------