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

           Summary: Postfix and prefix declarations of static
                    multidimensional arrays aren't equivalent
           Product: D
           Version: D2
          Platform: x86
        OS/Version: Windows
            Status: NEW
          Severity: normal
          Priority: P2
         Component: DMD
        AssignedTo: nob...@puremagic.com
        ReportedBy: fataler...@trash-mail.com


--- Comment #0 from fataler...@trash-mail.com 2012-08-10 10:16:19 PDT ---
I found this in v2.059 and v2.060.
Consider these 2 programs:
Pre:
void main()
{
  int m[3][2];
  foreach(i;0..3)
  {
    m[0][i]=0;
    m[1][i]=1;
  }
}

Post:
void main()
{
  int [3][2]m;
  foreach(i;0..3)
  {
    m[0][i]=0;
    m[1][i]=1;
  }
}

They only differ in the declaration of m.
Pre throws a range violation, but Post does not. This is a bug, because the
documentation for rectangular arrays claims
int [3][2]m;
int m[3][2];
to be equivalent declarations.

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

Reply via email to