Documentation ¶
Overview ¶
Package lint is a fork of golint (golang.org/x/lint) and contains a linter for Go source code.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func SetInitialism ¶
SetInitialism adds initialism entries for linting names and if they should be considered initialisms or not.
Only add entries that are highly unlikely to be non-initialisms. For instance, "ID" is fine (Freudian code is rare), but "AND" is not.
Types ¶
type Linter ¶
type Linter struct { }
A Linter lints Go source code.
type Problem ¶
type Problem struct { Position token.Position // position in source file Text string // the prose that describes the problem Link string // (optional) the link to the style guide for the problem Confidence float64 // a value in (0,1] estimating the confidence in this problem's correctness LineText string // the source line Category string // a short name for the general category of the problem // If the problem has a suggested fix (the minority case), // ReplacementLine is a full replacement for the relevant line of the source file. ReplacementLine string }
Problem represents a problem in some source code.
Click to show internal directories.
Click to hide internal directories.