www.digitalmars.com         C & C++   DMDScript  

digitalmars.D.bugs - [Issue 22925] New: importC: multi-dimensional array 'is not a static

https://issues.dlang.org/show_bug.cgi?id=22925

          Issue ID: 22925
           Summary: importC: multi-dimensional array 'is not a static and
                    cannot have static initializer'
           Product: D
           Version: D2
          Hardware: All
                OS: All
            Status: NEW
          Keywords: ImportC, rejects-valid
          Severity: normal
          Priority: P1
         Component: dmd
          Assignee: nobody puremagic.com
          Reporter: duser neet.fi
                CC: duser neet.fi

void fn()
{
        int arr[1][1] = { {1} };
}

Error: variable `test.fn.arr` is not a static and cannot have static
initializer

--
Mar 25 2022