[PATCH v3 1/4] dmime: Add a generic ParseDescriptor helper and use it for DMSegment