Parse DROP SCHEMA statement
(tokens: &[Token])
| 2665 | |
| 2666 | /// Parse DROP SCHEMA statement |
| 2667 | fn drop_schema_statement(tokens: &[Token]) -> IResult<&[Token], DropSchemaStatement> { |
| 2668 | map( |
| 2669 | tuple(( |
| 2670 | expect_token(Token::Drop), |
| 2671 | expect_token(Token::Schema), |
| 2672 | opt(tuple(( |
| 2673 | expect_token(Token::If), |
| 2674 | expect_token(Token::Exists), |
| 2675 | ))), |
| 2676 | catalog_path, |
| 2677 | opt(alt(( |
| 2678 | value(true, expect_token(Token::Cascade)), |
| 2679 | value(false, expect_token(Token::Restrict)), |
| 2680 | ))), |
| 2681 | )), |
| 2682 | |(_, _, if_exists, schema_path, cascade)| DropSchemaStatement { |
| 2683 | schema_path, |
| 2684 | if_exists: if_exists.is_some(), |
| 2685 | cascade: cascade.unwrap_or(false), |
| 2686 | location: Location::default(), |
| 2687 | }, |
| 2688 | )(tokens) |
| 2689 | } |
| 2690 | |
| 2691 | /// Parse CREATE GRAPH statement |
| 2692 | fn create_graph_statement(tokens: &[Token]) -> IResult<&[Token], CreateGraphStatement> { |
nothing calls this directly
no test coverage detected