Documentation ¶
Overview ¶
Package simple contains a linter for Go source code.
Index ¶
- Variables
- func LintAssertNotNil(f *lint.File)
- func LintBytesCompare(f *lint.File)
- func LintDeclareAssign(f *lint.File)
- func LintForTrue(f *lint.File)
- func LintFormatInt(f *lint.File)
- func LintIfBoolCmp(f *lint.File)
- func LintIfReturn(f *lint.File)
- func LintLoopAppend(f *lint.File)
- func LintLoopCopy(f *lint.File)
- func LintLoopSlide(f *lint.File)
- func LintMakeLenCap(f *lint.File)
- func LintRanges(f *lint.File)
- func LintReceiveIntoBlank(f *lint.File)
- func LintRedundantNilCheckWithLen(f *lint.File)
- func LintRegexpRaw(f *lint.File)
- func LintSimplerReturn(f *lint.File)
- func LintSimplerStructConversion(f *lint.File)
- func LintSingleCaseSelect(f *lint.File)
- func LintSlicing(f *lint.File)
- func LintStringsContains(f *lint.File)
- func LintTimeSince(f *lint.File)
- func LintTrim(f *lint.File)
- type Checker
Constants ¶
This section is empty.
Variables ¶
View Source
var Funcs = map[string]lint.Func{ "S1000": LintSingleCaseSelect, "S1001": LintLoopCopy, "S1002": LintIfBoolCmp, "S1003": LintStringsContains, "S1004": LintBytesCompare, "S1005": LintRanges, "S1006": LintForTrue, "S1007": LintRegexpRaw, "S1008": LintIfReturn, "S1009": LintRedundantNilCheckWithLen, "S1010": LintSlicing, "S1011": LintLoopAppend, "S1012": LintTimeSince, "S1013": LintSimplerReturn, "S1014": LintReceiveIntoBlank, "S1015": LintFormatInt, "S1016": LintSimplerStructConversion, "S1017": LintTrim, "S1018": LintLoopSlide, "S1019": LintMakeLenCap, "S1020": LintAssertNotNil, "S1021": LintDeclareAssign, }
Functions ¶
func LintAssertNotNil ¶
func LintBytesCompare ¶
func LintDeclareAssign ¶
func LintForTrue ¶
func LintFormatInt ¶
func LintIfBoolCmp ¶
func LintIfReturn ¶
func LintLoopAppend ¶
func LintLoopCopy ¶
func LintLoopSlide ¶
func LintMakeLenCap ¶
func LintRanges ¶
func LintReceiveIntoBlank ¶
func LintRedundantNilCheckWithLen ¶
LintRedundantNilCheckWithLen checks for the following reduntant nil-checks:
if x == nil || len(x) == 0 {} if x != nil && len(x) != 0 {} if x != nil && len(x) == N {} (where N != 0) if x != nil && len(x) > N {} if x != nil && len(x) >= N {} (where N != 0)
func LintRegexpRaw ¶
func LintSimplerReturn ¶
func LintSingleCaseSelect ¶
func LintSlicing ¶
func LintStringsContains ¶
func LintTimeSince ¶
Types ¶
Click to show internal directories.
Click to hide internal directories.