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

           Summary: Built-in runtime properties should become error with
                    `Type.prop`
           Product: D
           Version: D2
          Platform: All
        OS/Version: All
            Status: NEW
          Keywords: accepts-invalid, diagnostic
          Severity: minor
          Priority: P2
         Component: DMD
        AssignedTo: [email protected]
        ReportedBy: [email protected]


--- Comment #0 from Kenji Hara <[email protected]> 2013-02-21 18:40:42 PST ---
This code succeeds to compile with -o- switch.
It means that front-end allows such a meaningless expression, (int[]).length.

void main()
{
    foreach (A; TypeTuple!(int[1], char[1], int[], char[]))
    {
        auto len  = A.length;
        auto rev  = A.reverse;
        auto sort = A.sort;
        auto dup  = A.dup;
        auto idup = A.idup;
    }
}

Of course, the invalid expressions will fail code generation in glue layer, but
it is little late.

-- 
Configure issuemail: http://d.puremagic.com/issues/userprefs.cgi?tab=email
------- You are receiving this mail because: -------

Reply via email to