(node *ast.Node, symbolFlags ast.SymbolFlags, symbolExcludes ast.SymbolFlags)
| 431 | } |
| 432 | |
| 433 | func (b *Binder) declareSymbolAndAddToSymbolTable(node *ast.Node, symbolFlags ast.SymbolFlags, symbolExcludes ast.SymbolFlags) *ast.Symbol { |
| 434 | switch b.container.Kind { |
| 435 | case ast.KindModuleDeclaration: |
| 436 | return b.declareModuleMember(node, symbolFlags, symbolExcludes) |
| 437 | case ast.KindSourceFile: |
| 438 | return b.declareSourceFileMember(node, symbolFlags, symbolExcludes) |
| 439 | case ast.KindClassExpression, ast.KindClassDeclaration: |
| 440 | return b.declareClassMember(node, symbolFlags, symbolExcludes) |
| 441 | case ast.KindEnumDeclaration: |
| 442 | return b.declareSymbol(ast.GetExports(b.container.Symbol()), b.container.Symbol(), node, symbolFlags, symbolExcludes) |
| 443 | case ast.KindTypeLiteral, ast.KindObjectLiteralExpression, ast.KindInterfaceDeclaration, ast.KindJsxAttributes: |
| 444 | return b.declareSymbol(ast.GetMembers(b.container.Symbol()), b.container.Symbol(), node, symbolFlags, symbolExcludes) |
| 445 | case ast.KindFunctionType, ast.KindConstructorType, ast.KindCallSignature, ast.KindConstructSignature, |
| 446 | ast.KindIndexSignature, ast.KindMethodDeclaration, ast.KindMethodSignature, ast.KindConstructor, ast.KindGetAccessor, |
| 447 | ast.KindSetAccessor, ast.KindFunctionDeclaration, ast.KindFunctionExpression, ast.KindArrowFunction, |
| 448 | ast.KindClassStaticBlockDeclaration, ast.KindTypeAliasDeclaration, ast.KindJSTypeAliasDeclaration, ast.KindMappedType: |
| 449 | return b.declareSymbol(ast.GetLocals(b.container), nil /*parent*/, node, symbolFlags, symbolExcludes) |
| 450 | } |
| 451 | panic("Unhandled case in declareSymbolAndAddToSymbolTable") |
| 452 | } |
| 453 | |
| 454 | func (b *Binder) newFlowNode(flags ast.FlowFlags) *ast.FlowNode { |
| 455 | result := b.flowNodeArena.New() |
no test coverage detected