mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-09-28 12:54:58 +00:00
Fix some warnings
This commit is contained in:
parent
9707acb59b
commit
42057896bc
2 changed files with 2 additions and 2 deletions
|
@ -367,7 +367,7 @@ fn inner_attributes(
|
||||||
// Excerpt from the reference:
|
// Excerpt from the reference:
|
||||||
// Block expressions accept outer and inner attributes, but only when they are the outer
|
// Block expressions accept outer and inner attributes, but only when they are the outer
|
||||||
// expression of an expression statement or the final expression of another block expression.
|
// expression of an expression statement or the final expression of another block expression.
|
||||||
ast::BlockExpr(it) => return None,
|
ast::BlockExpr(_it) => return None,
|
||||||
_ => return None,
|
_ => return None,
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
|
@ -189,7 +189,7 @@ pub(crate) fn doc_owner_to_def(
|
||||||
) -> Option<Definition> {
|
) -> Option<Definition> {
|
||||||
let res: hir::ModuleDef = match_ast! {
|
let res: hir::ModuleDef = match_ast! {
|
||||||
match item {
|
match item {
|
||||||
ast::SourceFile(it) => sema.scope(&item).module()?.into(),
|
ast::SourceFile(_it) => sema.scope(&item).module()?.into(),
|
||||||
ast::Fn(it) => sema.to_def(&it)?.into(),
|
ast::Fn(it) => sema.to_def(&it)?.into(),
|
||||||
ast::Struct(it) => sema.to_def(&it)?.into(),
|
ast::Struct(it) => sema.to_def(&it)?.into(),
|
||||||
ast::Enum(it) => sema.to_def(&it)?.into(),
|
ast::Enum(it) => sema.to_def(&it)?.into(),
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue