resolveSymbolPropertyOfType resolves a type property of type `Symbol` and returns a symbol response.
(params *GetTypePropertyParams, getter func(*checker.Type) *ast.Symbol)
| 1639 | |
| 1640 | // resolveSymbolPropertyOfType resolves a type property of type `Symbol` and returns a symbol response. |
| 1641 | func (s *Session) resolveSymbolPropertyOfType(params *GetTypePropertyParams, getter func(*checker.Type) *ast.Symbol) (*SymbolResponse, error) { |
| 1642 | sd, err := s.getSnapshotData(params.Snapshot) |
| 1643 | if err != nil { |
| 1644 | return nil, err |
| 1645 | } |
| 1646 | |
| 1647 | t, err := sd.resolveTypeHandle(params.Project, params.Type) |
| 1648 | if err != nil { |
| 1649 | return nil, err |
| 1650 | } |
| 1651 | |
| 1652 | result := getter(t) |
| 1653 | if result == nil { |
| 1654 | return nil, nil |
| 1655 | } |
| 1656 | return sd.newSymbolResponse(result, params.Project), nil |
| 1657 | } |
| 1658 | |
| 1659 | // resolveSymbolTablePropertyOfSymbol resolves a symbol property of type `Symbol` and returns a symbol response. |
| 1660 | func (s *Session) resolveSymbolPropertyOfSymbol(params *GetSymbolPropertyParams, getter func(*ast.Symbol) *ast.Symbol) (*SymbolResponse, error) { |
no test coverage detected