MCPcopy
hub / github.com/microsoft/typescript-go / emitModuleExportName

Method emitModuleExportName

internal/printer/printer.go:1303–1316  ·  view source on GitHub ↗
(node *ast.ModuleExportName)

Source from the content-addressed store, hash-verified

1301}
1302
1303func (p *Printer) emitModuleExportName(node *ast.ModuleExportName) {
1304 if node == nil {
1305 return
1306 }
1307
1308 switch node.Kind {
1309 case ast.KindIdentifier:
1310 p.emitIdentifierName(node.AsIdentifier())
1311 case ast.KindStringLiteral:
1312 p.emitStringLiteral(node.AsStringLiteral())
1313 default:
1314 panic(fmt.Sprintf("unexpected ModuleExportName: %v", node.Kind))
1315 }
1316}
1317
1318func (p *Printer) emitImportAttributeName(node *ast.ImportAttributeName) {
1319 switch node.Kind {

Callers 3

emitImportSpecifierMethod · 0.95
emitNamespaceExportMethod · 0.95
emitExportSpecifierMethod · 0.95

Calls 5

emitIdentifierNameMethod · 0.95
emitStringLiteralMethod · 0.95
panicFunction · 0.85
AsIdentifierMethod · 0.80
AsStringLiteralMethod · 0.80

Tested by

no test coverage detected