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

           Summary: DMD allows "dereferencing" arrays as if it were a
                    pointer to first element
           Product: D
           Version: D2
          Platform: Other
        OS/Version: Windows
            Status: NEW
          Severity: normal
          Priority: P2
         Component: DMD
        AssignedTo: nob...@puremagic.com
        ReportedBy: 2kor...@gmail.com


--- Comment #0 from Koroskin Denis <2kor...@gmail.com> 2010-08-31 04:32:44 PDT 
---
import std.stdio;
void main()
{
    string foo = "foo";
    int[] bar = [ 42 ];

    writeln(*foo, *bar); // prints "f42"
}

I don't think this is intended and should be disallowed.

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

Reply via email to