mirror of
https://github.com/rust-lang/rust-analyzer
synced 2024-12-26 13:03:31 +00:00
Shorten some code
This commit is contained in:
parent
3e106c77ff
commit
5a6e770f99
1 changed files with 1 additions and 4 deletions
|
@ -230,10 +230,7 @@ fn check_unsize_impl_prerequisites(db: &impl HirDatabase, krate: CrateId) -> boo
|
|||
None => return false,
|
||||
};
|
||||
let generic_params = generics(db, unsize_trait.into());
|
||||
if generic_params.len() != 2 {
|
||||
return false;
|
||||
}
|
||||
true
|
||||
generic_params.len() == 2
|
||||
}
|
||||
|
||||
fn array_unsize_impl_datum(db: &impl HirDatabase, krate: CrateId) -> BuiltinImplData {
|
||||
|
|
Loading…
Reference in a new issue