github.com/pankona/gometalinter@v2.0.11+incompatible/_linters/src/mvdan.cc/lint/lint.go (about) 1 // Copyright (c) 2017, Daniel Martà <mvdan@mvdan.cc> 2 // See LICENSE for licensing information 3 4 // Package lint defines common interfaces for Go code checkers. 5 package lint // import "mvdan.cc/lint" 6 7 import ( 8 "go/token" 9 10 "golang.org/x/tools/go/loader" 11 "golang.org/x/tools/go/ssa" 12 ) 13 14 // A Checker points out issues in a program. 15 type Checker interface { 16 Program(*loader.Program) 17 Check() ([]Issue, error) 18 } 19 20 type WithSSA interface { 21 ProgramSSA(*ssa.Program) 22 } 23 24 // Issue represents an issue somewhere in a source code file. 25 type Issue interface { 26 Pos() token.Pos 27 Message() string 28 }