match_like_matches_macro

This commit is contained in:
Johann Hemmann 2024-01-19 15:14:29 +01:00
parent 2ae2512378
commit add40c8660
9 changed files with 29 additions and 43 deletions

View file

@ -186,14 +186,13 @@ impl TypeLocation {
}
pub(crate) fn complete_consts(&self) -> bool {
match self {
matches!(
self,
TypeLocation::GenericArg {
corresponding_param: Some(ast::GenericParam::ConstParam(_)),
..
} => true,
TypeLocation::AssocConstEq => true,
_ => false,
}
} | TypeLocation::AssocConstEq
)
}
pub(crate) fn complete_types(&self) -> bool {