[Issue 12766] New: Forward reference diagnostics must emit the offending line causing the forward reference
via Digitalmars-d-bugs
digitalmars-d-bugs at puremagic.com
Sun May 18 10:57:29 PDT 2014
https://issues.dlang.org/show_bug.cgi?id=12766
Issue ID: 12766
Summary: Forward reference diagnostics must emit the offending
line causing the forward reference
Product: D
Version: D2
Hardware: All
OS: All
Status: NEW
Keywords: diagnostic
Severity: major
Priority: P1
Component: DMD
Assignee: nobody at puremagic.com
Reporter: andrej.mitrovich at gmail.com
-----
struct A
{
B b; // L3
}
struct B // L6
{
A a; // L8
}
void main() { }
-----
$ test.d(6): Error: struct test.B no size yet for forward reference
This is a completely useless diagnostic, it doesn't tell me *what code* caused
the forward reference. It should either reference L3 or L8, not the line of the
beginning of the struct definition.
--
More information about the Digitalmars-d-bugs
mailing list