Regarding func (*Command) Usage(err interface{}) string, only values of err with types subCommandError and error are used by the function. Because subCommandError is an implementation of error, the argument should really be of type error.
It would be nice if it also accounted for string and fmt.Stringer, but I think documentation should at least note what the supported types are.
Regarding
func (*Command) Usage(err interface{}) string
, only values of err with types subCommandError and error are used by the function. Because subCommandError is an implementation of error, the argument should really be of type error.It would be nice if it also accounted for string and fmt.Stringer, but I think documentation should at least note what the supported types are.