@internal
()
| 820 | } |
| 821 | /** @internal */ |
| 822 | getParser(): SchemaParser.Parser { |
| 823 | let run: ReturnType<typeof this.run> |
| 824 | return (input, options) => { |
| 825 | if (input === InternalParser.missing) return InternalParser.missingExit |
| 826 | // Keep this declaration's initialization errors outside its callback catch. |
| 827 | run ??= this.run(this.typeParameters) |
| 828 | try { |
| 829 | return run(input, this, options) |
| 830 | } catch (error) { |
| 831 | return Effect.die(error) |
| 832 | } |
| 833 | } |
| 834 | } |
| 835 | /** @internal */ |
| 836 | recur(recur: (ast: AST) => AST): Declaration { |
| 837 | const typeParameters = mapOrSame(this.typeParameters, recur) |
nothing calls this directly
no test coverage detected