Fixed automatic serialization of the empty list and unit.