11292: internal: Decrease PartialOrd and PartialEq trait methods completion relevance r=Veykril a=Veykril


Fixes https://github.com/rust-analyzer/rust-analyzer/issues/10245
bors r+

Co-authored-by: Lukas Wirth <lukastw97@gmail.com>
This commit is contained in:
bors[bot] 2022-01-15 10:17:01 +00:00 committed by GitHub
commit 9ee5b89e52
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 2 deletions

View File

@ -940,6 +940,7 @@ fn has_ref(token: &SyntaxToken) -> bool {
"deref", "deref",
"div_assign", "div_assign",
"div", "div",
"eq",
"fn_mut", "fn_mut",
"fn_once", "fn_once",
"fn", "fn",
@ -949,6 +950,7 @@ fn has_ref(token: &SyntaxToken) -> bool {
"mul", "mul",
"neg", "neg",
"not", "not",
"partial_ord",
"rem_assign", "rem_assign",
"rem", "rem",
"shl_assign", "shl_assign",
@ -956,7 +958,6 @@ fn has_ref(token: &SyntaxToken) -> bool {
"shr_assign", "shr_assign",
"shr", "shr",
"sub", "sub",
"sub",
]; ];
#[cfg(test)] #[cfg(test)]
mod tests { mod tests {

View File

@ -139,7 +139,7 @@ pub struct CompletionRelevance {
/// } /// }
/// ``` /// ```
pub is_local: bool, pub is_local: bool,
/// Set for method completions of the `core::ops` family. /// Set for method completions of the `core::ops` and `core::cmp` family.
pub is_op_method: bool, pub is_op_method: bool,
/// This is set in cases like these: /// This is set in cases like these:
/// ///