mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-09-29 05:15:04 +00:00
Clippy lints
This commit is contained in:
parent
9467f81c58
commit
0d5d63a80e
16 changed files with 67 additions and 77 deletions
|
@ -168,8 +168,7 @@ pub fn let_stmt(pattern: ast::Pat, initializer: Option<ast::Expr>) -> ast::LetSt
|
|||
|
||||
fn ast_from_text<N: AstNode>(text: &str) -> N {
|
||||
let parse = SourceFile::parse(text);
|
||||
let res = parse.tree().syntax().descendants().find_map(N::cast).unwrap();
|
||||
res
|
||||
parse.tree().syntax().descendants().find_map(N::cast).unwrap()
|
||||
}
|
||||
|
||||
pub mod tokens {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue