MCPcopy Index your code
hub / github.com/microsoft/typescript-go / emitTypePredicateParameterName

Method emitTypePredicateParameterName

internal/printer/printer.go:1858–1867  ·  view source on GitHub ↗
(node *ast.TypePredicateParameterName)

Source from the content-addressed store, hash-verified

1856}
1857
1858func (p *Printer) emitTypePredicateParameterName(node *ast.TypePredicateParameterName) {
1859 switch node.Kind {
1860 case ast.KindIdentifier:
1861 p.emitIdentifierReference(node.AsIdentifier())
1862 case ast.KindThisType:
1863 p.emitThisType(node.AsThisTypeNode())
1864 default:
1865 panic(fmt.Sprintf("unexpected TypePredicateParameterName: %v", node.Kind))
1866 }
1867}
1868
1869func (p *Printer) emitTypePredicate(node *ast.TypePredicateNode) {
1870 state := p.enterNode(node.AsNode())

Callers 1

emitTypePredicateMethod · 0.95

Calls 5

emitThisTypeMethod · 0.95
panicFunction · 0.85
AsIdentifierMethod · 0.80
AsThisTypeNodeMethod · 0.80

Tested by

no test coverage detected