* True if we should not add definitions for both the signature symbol and the definition symbol. * True for `const |f = |() => 0`, false for `function |f() {} const |g = f;`. * Also true for any assignment RHS.
(s, calledDeclaration)
| 139786 | * Also true for any assignment RHS. |
| 139787 | */ |
| 139788 | function symbolMatchesSignature(s, calledDeclaration) { |
| 139789 | return s === calledDeclaration.symbol |
| 139790 | || s === calledDeclaration.symbol.parent |
| 139791 | || ts.isAssignmentExpression(calledDeclaration.parent) |
| 139792 | || (!ts.isCallLikeExpression(calledDeclaration.parent) && s === calledDeclaration.parent.symbol); |
| 139793 | } |
| 139794 | // If the current location we want to find its definition is in an object literal, try to get the contextual type for the |
| 139795 | // object literal, lookup the property symbol in the contextual type, and use this for goto-definition. |
| 139796 | // For example |
no outgoing calls
no test coverage detected