drop dead code

This commit is contained in:
Aleksey Kladov 2021-12-27 21:26:02 +03:00
parent 2cbfcf431e
commit 7e9c74d20b
35 changed files with 0 additions and 249 deletions

View file

@ -201,13 +201,6 @@ impl ast::Attr {
}
}
impl ast::Stmt {
/// Returns `text`, parsed as statement, but only if it has no errors.
pub fn parse(text: &str) -> Result<Self, ()> {
parsing::parse_text_as(text, parser::ParserEntryPoint::StatementOptionalSemi)
}
}
/// Matches a `SyntaxNode` against an `ast` type.
///
/// # Example:

View file

@ -59,15 +59,6 @@ fn validation_tests() {
});
}
#[test]
fn expr_parser_tests() {
fragment_parser_dir_test(
&["parser/fragments/expr/ok"],
&["parser/fragments/expr/err"],
crate::ast::Expr::parse,
);
}
#[test]
fn path_parser_tests() {
fragment_parser_dir_test(
@ -86,15 +77,6 @@ fn pattern_parser_tests() {
);
}
#[test]
fn stmt_parser_tests() {
fragment_parser_dir_test(
&["parser/fragments/stmt/ok"],
&["parser/fragments/stmt/err"],
crate::ast::Stmt::parse,
);
}
#[test]
fn parser_fuzz_tests() {
for (_, text) in collect_rust_files(&test_data_dir(), &["parser/fuzz-failures"]) {