Summary: error with passing an array slot as another array length
                    to new
           Product: D
           Version: unspecified
          Platform: PC
        OS/Version: Linux
            Status: NEW
          Severity: normal
          Priority: P2
         Component: DMD

void foo(uint n, in uint[] x)
    auto y = new uint[x[n]];

void main()
    foo(new uint[10]);

Error: need size of rightmost array, not type x[n]


Reply via email to