code: func mapToArray(m stringmapflag.Value) []*swarming.SwarmingRpcsStringPair {
  	a := make([]*swarming.SwarmingRpcsStringPair, 0, len(m))
  	for k, v := range m {
  		a = append(a, &swarming.SwarmingRpcsStringPair{Key: k, Value: v})
  	}
  
  	sort.Sort(array(a))
  	return a
  }
docs: // mapToArray converts a stringmapflag.Value into an array of
  // swarming.SwarmingRpcsStringPair, sorted by key and then value.