var species … var gopherType … func init() { … } type interval … // String is the method to format the flag's value, part of the flag.Value interface. // The String method's output will be used in diagnostics. func (i *interval) String() string { … } // Set is the method to set the flag value, part of the flag.Value interface. // Set's argument is a string to be parsed to set the flag. // It's a comma-separated list, so we split it. func (i *interval) Set(value string) error { … } var intervalFlag … func init() { … } func Example() { … }