Commit 3e60efb
authored
Update to golangci-lint
The currently latest `golangci-lint` version 1.39.0 [1] introduced new
linters and updated supported ones:
1. predeclared [2] (v1.35.0 [3]) - Checks for definitions and
declarations that shadows one of Go's pre-declared identifiers [4].
This linter is disabled by default, but is enabled for this template
to help to prevent shadowed identifiers.
2. interfacer [5] (v1.38.0 [6]) - Has been deprecated [7] and removed
from this template.
3. scopelint [8] (v1.39.0 [9]) - Has been deprecated [10] and replaced
by exportloopref [11].
The `exportloopref` linter is disabled by default, but is enabled for
this template to help to catch loop variable bugs.
[1]: https://github.com/golangci/golangci-lint/releases/tag/v1.39.0
[2]: https://github.com/nishanths/predeclared
[3]: https://github.com/golangci/golangci-lint/releases/tag/v1.35.0
[4]: https://golang.org/ref/spec#Predeclared_identifiers
[5]: https://github.com/mvdan/interfacer
[6]: https://github.com/golangci/golangci-lint/releases/tag/v1.38.0
[7]: golangci/golangci-lint#1755
[8]: https://github.com/kyoh86/scopelint
[9]: https://github.com/golangci/golangci-lint/releases/tag/v1.39.0
[10]: golangci/golangci-lint#1819
[11]: https://github.com/kyoh86/exportloopref
Closes GH-56v1.39.x (#57)1 parent 322ad30 commit 3e60efb
2 files changed
Lines changed: 3 additions & 4 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
51 | 51 | | |
52 | 52 | | |
53 | 53 | | |
54 | | - | |
| 54 | + | |
55 | 55 | | |
56 | 56 | | |
57 | 57 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
33 | 33 | | |
34 | 34 | | |
35 | 35 | | |
| 36 | + | |
36 | 37 | | |
37 | 38 | | |
38 | 39 | | |
| |||
49 | 50 | | |
50 | 51 | | |
51 | 52 | | |
52 | | - | |
53 | 53 | | |
54 | 54 | | |
55 | 55 | | |
56 | 56 | | |
57 | 57 | | |
58 | | - | |
59 | 58 | | |
60 | 59 | | |
61 | 60 | | |
| |||
147 | 146 | | |
148 | 147 | | |
149 | 148 | | |
150 | | - | |
| 149 | + | |
0 commit comments