mirror of
https://github.com/scratchfoundation/golangci-lint.git
synced 2025-08-13 23:08:45 -04:00
Update staticcheck and cache go/analysis facts (#699)
* update staticcheck Don't fork staticcheck: use the upstream version. Remove unneeded SSA loading. * Cache go/analysis facts Don't load unneeded packages for go/analysis. Repeated run of go/analysis linters now 10x faster (2s vs 20s on this repo) than before.
This commit is contained in:
parent
0e0cd753d2
commit
6a979fb40d
149 changed files with 19031 additions and 9474 deletions
|
@ -25,7 +25,7 @@ func getEnabledByDefaultFastLintersExcept(except ...string) []string {
|
|||
ebdl := m.GetAllEnabledByDefaultLinters()
|
||||
ret := []string{}
|
||||
for _, lc := range ebdl {
|
||||
if lc.NeedsDepsTypeInfo {
|
||||
if lc.IsSlowLinter() {
|
||||
continue
|
||||
}
|
||||
|
||||
|
@ -41,7 +41,7 @@ func getAllFastLintersWith(with ...string) []string {
|
|||
linters := lintersdb.NewManager(nil).GetAllSupportedLinterConfigs()
|
||||
ret := append([]string{}, with...)
|
||||
for _, lc := range linters {
|
||||
if lc.NeedsDepsTypeInfo {
|
||||
if lc.IsSlowLinter() {
|
||||
continue
|
||||
}
|
||||
ret = append(ret, lc.Name())
|
||||
|
@ -64,7 +64,7 @@ func getEnabledByDefaultFastLintersWith(with ...string) []string {
|
|||
ebdl := lintersdb.NewManager(nil).GetAllEnabledByDefaultLinters()
|
||||
ret := append([]string{}, with...)
|
||||
for _, lc := range ebdl {
|
||||
if lc.NeedsDepsTypeInfo {
|
||||
if lc.IsSlowLinter() {
|
||||
continue
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue