Skip to content

Commit 5f5d6c8

Browse files
committed
fix: put the right load mode for makezero and unused
1 parent 8db518c commit 5f5d6c8

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

pkg/golinters/makezero.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -56,5 +56,5 @@ func NewMakezero() *goanalysis.Linter {
5656
}
5757
}).WithIssuesReporter(func(*linter.Context) []goanalysis.Issue {
5858
return resIssues
59-
}).WithLoadMode(goanalysis.LoadModeSyntax | goanalysis.LoadModeTypesInfo)
59+
}).WithLoadMode(goanalysis.LoadModeTypesInfo)
6060
}

pkg/golinters/unused.go

+1-1
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ func NewUnused() *goanalysis.Linter {
5959
nil,
6060
).WithIssuesReporter(func(lintCtx *linter.Context) []goanalysis.Issue {
6161
return resIssues
62-
}).WithLoadMode(goanalysis.LoadModeSyntax | goanalysis.LoadModeTypesInfo)
62+
}).WithLoadMode(goanalysis.LoadModeWholeProgram)
6363

6464
return lnt
6565
}

0 commit comments

Comments
 (0)