Skip to content

Commit 3bc2404

Browse files
authored
deep-exit: fix mixed receiver type (lintDeepExit) (#1150)
1 parent 7e1d35d commit 3bc2404

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

rule/deep_exit.go

+2-2
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ func (*DeepExitRule) Apply(file *lint.File, _ lint.Arguments) []lint.Failure {
1717
failures = append(failures, failure)
1818
}
1919

20-
w := lintDeepExit{onFailure: onFailure, isTestFile: file.IsTest()}
20+
w := &lintDeepExit{onFailure: onFailure, isTestFile: file.IsTest()}
2121
ast.Walk(w, file.AST)
2222
return failures
2323
}
@@ -32,7 +32,7 @@ type lintDeepExit struct {
3232
isTestFile bool
3333
}
3434

35-
func (w lintDeepExit) Visit(node ast.Node) ast.Visitor {
35+
func (w *lintDeepExit) Visit(node ast.Node) ast.Visitor {
3636
if fd, ok := node.(*ast.FuncDecl); ok {
3737
if w.mustIgnore(fd) {
3838
return nil // skip analysis of this function

0 commit comments

Comments
 (0)