| 422 | } |
| 423 | |
| 424 | Result<ValueSchema> ValueSchemaParser::parse(std::string_view str) { |
| 425 | TextParser parser(str); |
| 426 | auto result = parse(parser); |
| 427 | if (!result) { |
| 428 | return parser.getError(); |
| 429 | } |
| 430 | if (!parser.ensureIsAtEnd()) { |
| 431 | return parser.getError(); |
| 432 | } |
| 433 | return result.value(); |
| 434 | } |
| 435 | |
| 436 | using ValueSchemaTypeParserFn = std::optional<ValueSchema> (*)(TextParser& parser); |
| 437 |
no test coverage detected