We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 183765e commit 7c49721Copy full SHA for 7c49721
pkg/golinters/gochecknoglobals.go
@@ -49,7 +49,7 @@ func (lint Gochecknoglobals) checkFile(f *ast.File, fset *token.FileSet) []resul
49
}
50
51
res = append(res, result.Issue{
52
- Pos: fset.Position(genDecl.TokPos),
+ Pos: fset.Position(vn.Pos()),
53
Text: fmt.Sprintf("%s is a global variable", formatCode(vn.Name, nil)),
54
FromLinter: lint.Name(),
55
})
0 commit comments