Internal helper for sizeIntegral() that takes the dimnames of each labelled
dimension from the first of the given arrays that has them.
collect_dimnames(target_labels, arrays, labels)A named list of dimnames, or NULL if none of the arrays has any.
The dimension labels of the result.
A list of arrays.
A list of the corresponding label vectors.