Gofmt formats Go programs. We run gofmt -s
on your code, where -s
is for the "simplify" command
No problems detected. Good job!
go vet
examines Go source code and reports suspicious constructs, such as Printf calls whose arguments do not align with the format string.
No problems detected. Good job!
Gocyclo calculates cyclomatic complexities of functions in Go source code.
The cyclomatic complexity of a function is calculated according to the following rules:
1 is the base complexity of a function
+1 for each 'if', 'for', 'case', '&&' or '||'
Go Report Card warns on functions with cyclomatic complexity > 15.
No problems detected. Good job!
Golint is a linter for Go source code.
-
go-imagequant/Image.go
- Line 30: warning: exported type Image should have comment or be unexported (golint)
- Line 37: warning: comment on exported function NewImage should be of the form "NewImage ..." (golint)
- Line 58: warning: comment on exported method Image.Release should be of the form "Release ..." (golint)
- Line 59: warning: receiver name should be a reflection of its identity; don't use generic names such as "this" or "self" (golint)
- Line 65: warning: comment on exported method Image.Quantize should be of the form "Quantize ..." (golint)
- Line 66: warning: receiver name should be a reflection of its identity; don't use generic names such as "this" or "self" (golint)
-
go-imagequant/Result.go
- Line 29: warning: comment on exported type Result should be of the form "Result ..." (with optional leading article) (golint)
- Line 36: warning: comment on exported method Result.SetDitheringLevel should be of the form "SetDitheringLevel ..." (golint)
- Line 39: warning: receiver name should be a reflection of its identity; don't use generic names such as "this" or "self" (golint)
- Line 39: warning: don't use underscores in Go names; method parameter dither_level should be ditherLevel (golint)
- Line 43: warning: comment on exported method Result.GetQuantizationError should be of the form "GetQuantizationError ..." (golint)
- Line 48: warning: receiver name should be a reflection of its identity; don't use generic names such as "this" or "self" (golint)
- Line 52: warning: comment on exported method Result.GetRemappingError should be of the form "GetRemappingError ..." (golint)
- Line 55: warning: receiver name should be a reflection of its identity; don't use generic names such as "this" or "self" (golint)
- Line 59: warning: comment on exported method Result.GetQuantizationQuality should be of the form "GetQuantizationQuality ..." (golint)
- Line 60: warning: receiver name should be a reflection of its identity; don't use generic names such as "this" or "self" (golint)
- Line 64: warning: comment on exported method Result.GetRemappingQuality should be of the form "GetRemappingQuality ..." (golint)
- Line 65: warning: receiver name should be a reflection of its identity; don't use generic names such as "this" or "self" (golint)
- Line 69: warning: comment on exported method Result.SetOutputGamma should be of the form "SetOutputGamma ..." (golint)
- Line 72: warning: receiver name should be a reflection of its identity; don't use generic names such as "this" or "self" (golint)
- Line 76: warning: exported method Result.GetImageWidth should have comment or be unexported (golint)
- Line 76: warning: receiver name should be a reflection of its identity; don't use generic names such as "this" or "self" (golint)
- Line 81: warning: exported method Result.GetImageHeight should have comment or be unexported (golint)
- Line 81: warning: receiver name should be a reflection of its identity; don't use generic names such as "this" or "self" (golint)
- Line 86: warning: exported method Result.GetOutputGamma should have comment or be unexported (golint)
- Line 86: warning: receiver name should be a reflection of its identity; don't use generic names such as "this" or "self" (golint)
- Line 90: warning: comment on exported method Result.WriteRemappedImage should be of the form "WriteRemappedImage ..." (golint)
- Line 91: warning: receiver name should be a reflection of its identity; don't use generic names such as "this" or "self" (golint)
- Line 96: warning: don't use underscores in Go names; var buff_size should be buffSize (golint)
- Line 108: warning: comment on exported method Result.GetPalette should be of the form "GetPalette ..." (golint)
- Line 110: warning: receiver name should be a reflection of its identity; don't use generic names such as "this" or "self" (golint)
- Line 127: warning: comment on exported method Result.Release should be of the form "Release ..." (golint)
- Line 128: warning: receiver name should be a reflection of its identity; don't use generic names such as "this" or "self" (golint)
-
go-imagequant/imagequant.go
- Line 34: warning: exported var ErrQualityTooLow should have comment or be unexported (golint)
- Line 68: warning: exported function GetLibraryVersion should have comment or be unexported (golint)
- Line 72: warning: exported function GetLibraryVersionString should have comment or be unexported (golint)
-
go-imagequant/Attributes.go
- Line 30: warning: exported type Attributes should have comment or be unexported (golint)
- Line 34: warning: comment on exported function NewAttributes should be of the form "NewAttributes ..." (golint)
- Line 46: warning: exported const COLORS_MIN should have comment (or a comment on this block) or be unexported (golint)
- Line 50: warning: comment on exported method Attributes.SetMaxColors should be of the form "SetMaxColors ..." (golint)
- Line 52: warning: receiver name should be a reflection of its identity; don't use generic names such as "this" or "self" (golint)
- Line 56: warning: exported method Attributes.GetMaxColors should have comment or be unexported (golint)
- Line 56: warning: receiver name should be a reflection of its identity; don't use generic names such as "this" or "self" (golint)
- Line 61: warning: exported const QUALITY_MIN should have comment (or a comment on this block) or be unexported (golint)
- Line 65: warning: comment on exported method Attributes.SetQuality should be of the form "SetQuality ..." (golint)
- Line 74: warning: receiver name should be a reflection of its identity; don't use generic names such as "this" or "self" (golint)
- Line 78: warning: exported method Attributes.GetMinQuality should have comment or be unexported (golint)
- Line 78: warning: receiver name should be a reflection of its identity; don't use generic names such as "this" or "self" (golint)
- Line 82: warning: exported method Attributes.GetMaxQuality should have comment or be unexported (golint)
- Line 82: warning: receiver name should be a reflection of its identity; don't use generic names such as "this" or "self" (golint)
- Line 87: warning: exported const SPEED_SLOWEST should have comment (or a comment on this block) or be unexported (golint)
- Line 92: warning: comment on exported method Attributes.SetSpeed should be of the form "SetSpeed ..." (golint)
- Line 94: warning: receiver name should be a reflection of its identity; don't use generic names such as "this" or "self" (golint)
- Line 98: warning: exported method Attributes.GetSpeed should have comment or be unexported (golint)
- Line 98: warning: receiver name should be a reflection of its identity; don't use generic names such as "this" or "self" (golint)
- Line 102: warning: comment on exported method Attributes.SetMinOpacity should be of the form "SetMinOpacity ..." (golint)
- Line 104: warning: receiver name should be a reflection of its identity; don't use generic names such as "this" or "self" (golint)
- Line 108: warning: exported method Attributes.GetMinOpacity should have comment or be unexported (golint)
- Line 108: warning: receiver name should be a reflection of its identity; don't use generic names such as "this" or "self" (golint)
- Line 112: warning: comment on exported method Attributes.SetMinPosterization should be of the form "SetMinPosterization ..." (golint)
- Line 116: warning: receiver name should be a reflection of its identity; don't use generic names such as "this" or "self" (golint)
- Line 120: warning: exported method Attributes.GetMinPosterization should have comment or be unexported (golint)
- Line 120: warning: receiver name should be a reflection of its identity; don't use generic names such as "this" or "self" (golint)
- Line 124: warning: comment on exported method Attributes.SetLastIndexTransparent should be of the form "SetLastIndexTransparent ..." (golint)
- Line 127: warning: receiver name should be a reflection of its identity; don't use generic names such as "this" or "self" (golint)
- Line 127: warning: don't use underscores in Go names; method parameter is_last should be isLast (golint)
- Line 131: warning: comment on exported method Attributes.CreateHistogram should be of the form "CreateHistogram ..." (golint)
- Line 133: warning: receiver name should be a reflection of its identity; don't use generic names such as "this" or "self" (golint)
- Line 138: warning: comment on exported method Attributes.Release should be of the form "Release ..." (golint)
- Line 139: warning: receiver name should be a reflection of its identity; don't use generic names such as "this" or "self" (golint)
-
go-imagequant/Histogram.go
- Line 24: warning: exported type Histogram should have comment or be unexported (golint)
- Line 28: warning: comment on exported method Histogram.AddImage should be of the form "AddImage ..." (golint)
- Line 31: warning: receiver name should be a reflection of its identity; don't use generic names such as "this" or "self" (golint)
- Line 36: warning: receiver name should be a reflection of its identity; don't use generic names such as "this" or "self" (golint)
- Line 46: warning: comment on exported method Histogram.Release should be of the form "Release ..." (golint)
- Line 47: warning: receiver name should be a reflection of its identity; don't use generic names such as "this" or "self" (golint)
Checks whether your project has a LICENSE file.
No problems detected. Good job!
IneffAssign detects ineffectual assignments in Go code.
No problems detected. Good job!
Misspell Finds commonly misspelled English words
No problems detected. Good job!