File tree Expand file tree Collapse file tree 2 files changed +2
-2
lines changed Expand file tree Collapse file tree 2 files changed +2
-2
lines changed Original file line number Diff line number Diff line change @@ -43,7 +43,7 @@ func (p *Panicable) At(i int) ast.Node {
43
43
const Doc = "forcetypeassert is finds type assertions which did forcely"
44
44
45
45
func run (pass * analysis.Pass ) (interface {}, error ) {
46
- inspect := pass .ResultOf [inspect .Analyzer ].(* inspector.Inspector )
46
+ inspect , _ := pass .ResultOf [inspect .Analyzer ].(* inspector.Inspector )
47
47
result := & Panicable {m : make (map [ast.Node ]bool )}
48
48
49
49
nodeFilter := []ast.Node {
Original file line number Diff line number Diff line change @@ -22,7 +22,7 @@ func TestResult(t *testing.T) {
22
22
forcetypeassert .Analyzer ,
23
23
},
24
24
Run : func (pass * analysis.Pass ) (interface {}, error ) {
25
- panicable := pass .ResultOf [forcetypeassert .Analyzer ].(* forcetypeassert.Panicable )
25
+ panicable , _ := pass .ResultOf [forcetypeassert .Analyzer ].(* forcetypeassert.Panicable )
26
26
for i := 0 ; i < panicable .Len (); i ++ {
27
27
n := panicable .At (i )
28
28
pass .Reportf (n .Pos (), "panicable" )
You can’t perform that action at this time.
0 commit comments