Refactor homogeneous datatype.