SystemVerilog accepts a single number, as an alternative to a
range, to specify the size of an unpacked array, like C. That is, [size] becomes the same as [size-1:00:size-1]. For example:
int Array[8][32]; is the same as: int Array[7:0][31:0][0:7][0:31];
Passing fixed-size arrays as arguments to subroutines requires
that the actual argument and the formal argument in the function declaration be
of the compatible type and that all sized dimensions
be of the same size. Note that unsized dimensions may occur in dynamic arrays and in
formal arguments of import DPI functions. If one of dimensions of a formal is unsized, then any size of the corresponding dimension of an
actual is accepted.
For example, the declaration:
task
foo( string arr[] );
declares a task that
accepts one argument, a dynamic array of 4 strings. This task can accept any
one-dimensional array of strings or any dynamic array of strings.
An import DPI
function that accepts a one-dimensional array can be passed a dynamic array of
a compatible type and of any size if formal is unsized,
and of the same size if formal is sized.