How did you go about doing the re-ordering? I am struggling with the same problem for maps, but I cannot get my ordering right without ruining the structure
for example:
This:
var strStatus = map[Status]string{
StatusInvalid: "Invalid",
StatusCreated: "Created",
StatusDisabled: "Disabled",
StatusActive: "Active",
StatusInactive: "Inactive",
}
Becomes This:
var strStatus = map[Status]string{StatusActive: "Active", StatusCreated: "Created",
StatusDisabled: "Disabled",
StatusInactive: "Inactive", StatusInvalid: "Invalid"}
I don't want to have to do find and replace with and search for commas and so on, so how did you go about maintaining the output format?