Compile::cpdsts
The length of the second argument must be known:
Compile[{}, Partition[{1, 2, 3, 4}, x], {{x, _Integer, 1}}]The rank of the result of Partition can be determined from the form of the arguments:
Compile[{}, Partition[{1, 2, 3, 4}, {n1, n2}], {{n1, _Integer}, {n2, _Integer}}]