(&mut self)
| 4642 | } |
| 4643 | |
| 4644 | fn parse_cluster_option_replicas(&mut self) -> Result<ClusterOption<Raw>, ParserError> { |
| 4645 | let _ = self.consume_token(&Token::Eq); |
| 4646 | self.expect_token(&Token::LParen)?; |
| 4647 | let replicas = if self.consume_token(&Token::RParen) { |
| 4648 | vec![] |
| 4649 | } else { |
| 4650 | let replicas = self.parse_comma_separated(|parser| { |
| 4651 | let name = parser.parse_identifier()?; |
| 4652 | parser.expect_token(&Token::LParen)?; |
| 4653 | let options = parser.parse_comma_separated(Parser::parse_replica_option)?; |
| 4654 | parser.expect_token(&Token::RParen)?; |
| 4655 | Ok(ReplicaDefinition { name, options }) |
| 4656 | })?; |
| 4657 | self.expect_token(&Token::RParen)?; |
| 4658 | replicas |
| 4659 | }; |
| 4660 | Ok(ClusterOption { |
| 4661 | name: ClusterOptionName::Replicas, |
| 4662 | value: Some(WithOptionValue::ClusterReplicas(replicas)), |
| 4663 | }) |
| 4664 | } |
| 4665 | |
| 4666 | fn parse_cluster_option_schedule(&mut self) -> Result<ClusterOption<Raw>, ParserError> { |
| 4667 | let _ = self.consume_token(&Token::Eq); |
no test coverage detected