doc: fix typo and improve docs for sorting

This commit is contained in:
2021-08-09 10:12:31 +02:00
parent 78d2fa7a60
commit 8c998c0043
2 changed files with 8 additions and 8 deletions

View File

@ -18,7 +18,7 @@ type Tag struct {
UsesV bool // whether or not the tag uses the "v" prefix
}
// ByTag sorts tags
// ByTag sorts tags in asc/desc order where the last element is the latest tag.
type ByTag []Tag
func (t ByTag) Len() int { return len(t) }
@ -299,8 +299,8 @@ func Parse(tag string) (Tag, error) {
return parsedTag, nil
}
// IsParseable determines if a tag is supported by this library
func IsParseable(tag string) bool {
// IsParsable determines if a tag is supported by this library
func IsParsable(tag string) bool {
if _, err := Parse(tag); err != nil {
return false
}