http://d.puremagic.com/issues/show_bug.cgi?id=9635
Summary: Improved error message for failed access of array
field properties from static method
Product: D
Version: D2
Platform: All
OS/Version: All
Status: NEW
Keywords: diagnostic
Severity: enhancement
Priority: P2
Component: DMD
AssignedTo: [email protected]
ReportedBy: [email protected]
--- Comment #0 from [email protected] 2013-03-02 12:08:03 PST ---
Spinoff of issue 9630
This program:
struct Foo {
int i[1];
static void bar() {
assert(0 < i[0].max);
}
}
Currently gives:
temp.d(4): Error: need 'this' for i type int[1u].
Andrej Mitrovic suggests:
> This is already a bad message. 'i' should be quoted and the wording should be
> improved:
> temp.d(4): Error: need 'this' for 'i' of type int[1u]
Is it possible to generate an error message like this, that suggests how to fix
the problem?
temp.d(4): Error: need 'this' for 'i' of type int[1u]. Use typeof(i[0]).max
instead
--
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------