1
0
mirror of https://github.com/alecthomas/chroma.git synced 2025-11-29 22:47:29 +02:00

Add golangci-lint and fix all lint issues.

This commit is contained in:
Alec Thomas
2018-12-31 22:44:27 +11:00
parent e27f19c12f
commit da5ac60d8c
18 changed files with 118 additions and 45 deletions

View File

@@ -127,6 +127,7 @@ func MustParseColour(colour string) Colour {
return parsed
}
// IsSet returns true if the colour is set.
func (c Colour) IsSet() bool { return c != 0 }
func (c Colour) String() string { return fmt.Sprintf("#%06x", int(c-1)) }