[Issue 4723] New: AssociativeArray's bug

d-bugmail at puremagic.com d-bugmail at puremagic.com
Wed Aug 25 06:00:11 PDT 2010


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

           Summary: AssociativeArray's bug
           Product: D
           Version: D2
          Platform: Other
               URL: http://hibari.2ch.net/test/read.cgi/tech/1281826764/43
                    -44
        OS/Version: Windows
            Status: NEW
          Severity: normal
          Priority: P2
         Component: DMD
        AssignedTo: nobody at puremagic.com
        ReportedBy: zan77137 at nifty.com
        Depends on: 3962


--- Comment #0 from SHOO <zan77137 at nifty.com> 2010-08-25 06:00:00 PDT ---
This code doesn't work:

void main() {
    int[int] a = (int[int]).init;
    a[1] = 2;
}

This makes runtime error:

object.Error: Integer Divide by Zero 




And this:

void main() {
    int[int] a = (int[int]).init;
    a[1] = 2;
}

This makes compiletime error:
Error: incompatible types for ((a) == (AssociativeArray(null))): 'int[int]' and
'AssociativeArray!(int,int)'



These bug probably depends on this:
    http://d.puremagic.com/issues/show_bug.cgi?id=3962

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