fields in correct order
support for enums