nolinter

package
v0.1.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 24, 2020 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var Analyzer = &analysis.Analyzer{
	Name:       "nolinter",
	Doc:        "required by other analyzers to have access to source code comments matchin //nolint pattern",
	Run:        run,
	ResultType: reflect.TypeOf([]NolintComment{}),
}

Analyzer required by other analyzers to have access to source code comments matchin //nolint pattern.

Functions

func IsSupressed

func IsSupressed(pass *analysis.Pass, pos token.Pos, nextTokenPos token.Pos) bool

IsSupressed checks whether there is a nolint comment on the given line

Types

type NolintComment

type NolintComment struct {
	Comment string
	Pos     token.Pos
	End     token.Pos
}

NolintComment describes known facts about //nolint comment

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL