MCPcopy Create free account
hub / github.com/arktypeio/arktype / refToId

Method refToId

ark/type/standalone/compilers.ts:634–642  ·  view source on GitHub ↗
(id: NodeId, opts?: ReferenceOptions)

Source from the content-addressed store, hash-verified

632// reporting only to a ctx
633class UnifiedCompiler extends StandaloneCompiler {
634 override refToId(id: NodeId, opts?: ReferenceOptions): string {
635 const node = this.link.byId[id]
636 return super.refToId(
637 id,
638 node && (opts?.kind ?? this.trav) === "Apply" && this.unifies(node) ?
639 { ...opts, kind: "Allows" }
640 : opts
641 )
642 }
643
644 override needsCtxFor(
645 node: BaseNode,

Callers

nothing calls this directly

Calls 2

refToIdMethod · 0.65
unifiesMethod · 0.45

Tested by

no test coverage detected