.gitignore added
[dotfiles/.git] / .config / coc / extensions / coc-go-data / tools / pkg / mod / honnef.co / go / tools@v0.1.1 / analysis / facts / directives.go
1 package facts
2
3 import (
4         "reflect"
5
6         "golang.org/x/tools/go/analysis"
7         "honnef.co/go/tools/analysis/lint"
8 )
9
10 func directives(pass *analysis.Pass) (interface{}, error) {
11         return lint.ParseDirectives(pass.Files, pass.Fset), nil
12 }
13
14 var Directives = &analysis.Analyzer{
15         Name:             "directives",
16         Doc:              "extracts linter directives",
17         Run:              directives,
18         RunDespiteErrors: true,
19         ResultType:       reflect.TypeOf([]lint.Directive{}),
20 }