(pass *analysis.Pass, expr ast.Expr)
| 395 | } |
| 396 | |
| 397 | func (m outerStoreMatcher) matches(pass *analysis.Pass, expr ast.Expr) bool { |
| 398 | form := exprFormFor(pass, expr) |
| 399 | if form.text == "" { |
| 400 | return false |
| 401 | } |
| 402 | |
| 403 | for _, storeForm := range m.storeForms { |
| 404 | if sameExprForm(form, storeForm) { |
| 405 | return true |
| 406 | } |
| 407 | } |
| 408 | |
| 409 | if m.fieldSuffix == "" { |
| 410 | return false |
| 411 | } |
| 412 | |
| 413 | for _, ownerForm := range m.ownerForms { |
| 414 | if sameExprFormWithSuffix(form, ownerForm, m.fieldSuffix) { |
| 415 | return true |
| 416 | } |
| 417 | } |
| 418 | |
| 419 | return false |
| 420 | } |
| 421 | |
| 422 | func (m outerStoreMatcher) matchesOwner(pass *analysis.Pass, expr ast.Expr) bool { |
| 423 | if len(m.ownerForms) == 0 { |
no test coverage detected