(node *Node)
| 3564 | } |
| 3565 | |
| 3566 | func IsTypeDeclaration(node *Node) bool { |
| 3567 | switch node.Kind { |
| 3568 | case KindTypeParameter, KindClassDeclaration, KindInterfaceDeclaration, KindTypeAliasDeclaration, KindJSTypeAliasDeclaration, KindEnumDeclaration: |
| 3569 | return true |
| 3570 | case KindImportClause: |
| 3571 | return node.IsTypeOnly() |
| 3572 | case KindImportSpecifier, KindExportSpecifier: |
| 3573 | return node.Parent.Parent.IsTypeOnly() |
| 3574 | default: |
| 3575 | return false |
| 3576 | } |
| 3577 | } |
| 3578 | |
| 3579 | func IsTypeDeclarationName(name *Node) bool { |
| 3580 | return name.Kind == KindIdentifier && |
no test coverage detected