[Issue 9574] New: Diagnostic for old use of 'alias this = that' should be informative

d-bugmail at puremagic.com d-bugmail at puremagic.com
Fri Feb 22 13:07:00 PST 2013


http://d.puremagic.com/issues/show_bug.cgi?id=9574

           Summary: Diagnostic for old use of 'alias this = that' should
                    be informative
           Product: D
           Version: D2
          Platform: All
        OS/Version: All
            Status: NEW
          Keywords: diagnostic
          Severity: enhancement
          Priority: P2
         Component: druntime
        AssignedTo: andrej.mitrovich at gmail.com
        ReportedBy: andrej.mitrovich at gmail.com


--- Comment #0 from Andrej Mitrovic <andrej.mitrovich at gmail.com> 2013-02-22 13:06:58 PST ---
module test;
struct Foo
{
    int x;
    alias this = x;
}

2.062:
$ dmd test.d

> test.d(6): Error: no identifier for declarator this
> test.d(6): Error: alias cannot have initializer

This should be an informative message. At first it should state only 'alias x
this;' is supported. When we get the new 'alias this : that' syntax we'll
update the diagnostic to reflect that.

-- 
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