[swift2thrift] write struct fields ordered by id