| 948 | to = to.annotations({ [AST.AutoTitleAnnotationId]: format(Tuple(...schemas)) }) |
| 949 | } |
| 950 | return class TemplateLiteralParserClass extends transformOrFail(from, to, { |
| 951 | strict: false, |
| 952 | decode: (i, _, ast) => { |
| 953 | const match = re.exec(i) |
| 954 | return match |
| 955 | ? ParseResult.succeed(match.slice(1, params.length + 1)) |
| 956 | : ParseResult.fail(new ParseResult.Type(ast, i, `${re.source}: no match for ${JSON.stringify(i)}`)) |
| 957 | }, |
| 958 | encode: (tuple) => ParseResult.succeed(tuple.join("")) |
| 959 | }) { |
| 960 | static params = params.slice() |
| 961 | } as any |
| 962 | } |
| 963 | |
| 964 | const declareConstructor = < |
nothing calls this directly
no test coverage detected