From eb9983b7225aef76dbf844af829dc80c615f16a5 Mon Sep 17 00:00:00 2001 From: Aleksey Bakin Date: Sat, 29 Jan 2022 00:41:23 +0300 Subject: [PATCH] chore: fix typo --- pkg/analyzer/analyzer.go | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/pkg/analyzer/analyzer.go b/pkg/analyzer/analyzer.go index d5052c1..fd4bfdd 100644 --- a/pkg/analyzer/analyzer.go +++ b/pkg/analyzer/analyzer.go @@ -420,7 +420,7 @@ func unwrapTestingFunctionBuilding(pass *analysis.Pass, expr ast.Expr, testFuncT funcDecl.Body = funObjDecl.Body funcDecl.Type = funObjDecl.Type case *ast.SelectorExpr: - fd := findSelectroDeclaration(pass, f) + fd := findSelectorDeclaration(pass, f) if fd == nil { return nil } @@ -499,8 +499,8 @@ func isExprHasType(pass *analysis.Pass, expr ast.Expr, expType types.Type) bool return types.Identical(typeInfo.Type, expType) } -// findSelectroDeclaration returns function declaration called by selectro expression. -func findSelectroDeclaration(pass *analysis.Pass, expr *ast.SelectorExpr) *ast.FuncDecl { +// findSelectorDeclaration returns function declaration called by selector expression. +func findSelectorDeclaration(pass *analysis.Pass, expr *ast.SelectorExpr) *ast.FuncDecl { xsel, ok := pass.TypesInfo.Selections[expr] if !ok { return nil