mirror of
https://github.com/rust-lang/rust-analyzer.git
synced 2025-08-19 01:50:32 +00:00
Fix warnings on rust-nightly
This commit is contained in:
parent
a88d4f8c72
commit
59fe884ef5
3 changed files with 4 additions and 4 deletions
|
@ -94,7 +94,7 @@ pub fn filter_assoc_items(
|
||||||
ast::AssocItem::MacroCall(_) => None,
|
ast::AssocItem::MacroCall(_) => None,
|
||||||
}
|
}
|
||||||
.is_some()
|
.is_some()
|
||||||
};
|
}
|
||||||
|
|
||||||
items
|
items
|
||||||
.iter()
|
.iter()
|
||||||
|
|
|
@ -679,7 +679,7 @@ fn schema(fields: &[(&'static str, &'static str, &[&str], &str)]) -> serde_json:
|
||||||
for ((f1, ..), (f2, ..)) in fields.iter().zip(&fields[1..]) {
|
for ((f1, ..), (f2, ..)) in fields.iter().zip(&fields[1..]) {
|
||||||
fn key(f: &str) -> &str {
|
fn key(f: &str) -> &str {
|
||||||
f.splitn(2, "_").next().unwrap()
|
f.splitn(2, "_").next().unwrap()
|
||||||
};
|
}
|
||||||
assert!(key(f1) <= key(f2), "wrong field order: {:?} {:?}", f1, f2);
|
assert!(key(f1) <= key(f2), "wrong field order: {:?} {:?}", f1, f2);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -220,7 +220,7 @@ impl ast::RecordExprFieldList {
|
||||||
InsertPosition::After($anchor.syntax().clone().into())
|
InsertPosition::After($anchor.syntax().clone().into())
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
};
|
}
|
||||||
|
|
||||||
let position = match position {
|
let position = match position {
|
||||||
InsertPosition::First => after_l_curly!(),
|
InsertPosition::First => after_l_curly!(),
|
||||||
|
@ -533,7 +533,7 @@ impl ast::GenericParamList {
|
||||||
InsertPosition::After($anchor.syntax().clone().into())
|
InsertPosition::After($anchor.syntax().clone().into())
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
};
|
}
|
||||||
|
|
||||||
let position = match self.generic_params().last() {
|
let position = match self.generic_params().last() {
|
||||||
Some(it) => after_field!(it),
|
Some(it) => after_field!(it),
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue