MCPcopy Create free account
hub / github.com/Effect-TS/tsgo / formatExecutionSourceNode

Function formatExecutionSourceNode

internal/effecttest/baseline.go:457–462  ·  view source on GitHub ↗
(sf *ast.SourceFile, node *ast.Node)

Source from the content-addressed store, hash-verified

455}
456
457func formatExecutionSourceNode(sf *ast.SourceFile, node *ast.Node) string {
458 if sf == nil || node == nil {
459 return ""
460 }
461 return escapeNewlines(scanner.GetSourceTextOfNodeFromSourceFile(sf, node, false))
462}
463
464// escapeNewlines replaces newlines with \n for baseline display.
465func escapeNewlines(s string) string {

Callers 1

Calls 1

escapeNewlinesFunction · 0.85

Tested by

no test coverage detected