aboutsummaryrefslogtreecommitdiff
path: root/crates/ide/src/syntax_highlighting.rs
diff options
context:
space:
mode:
authorAnatol Liu <[email protected]>2020-11-05 04:08:46 +0000
committerAnatol Liu <[email protected]>2020-11-08 08:01:02 +0000
commit90031a267a2ea510cede2ab5c3164bb8605a69ac (patch)
tree154b5d51ed2b68823115840834f00e56ec30098f /crates/ide/src/syntax_highlighting.rs
parent3aa0e40726b44564e5f68612517d0d65d519275a (diff)
Add static semantic token modifier for associated functions with no &self
refactor logic into code_model.rs address comments
Diffstat (limited to 'crates/ide/src/syntax_highlighting.rs')
-rw-r--r--crates/ide/src/syntax_highlighting.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/crates/ide/src/syntax_highlighting.rs b/crates/ide/src/syntax_highlighting.rs
index 3fcdb5e52..41fd36edf 100644
--- a/crates/ide/src/syntax_highlighting.rs
+++ b/crates/ide/src/syntax_highlighting.rs
@@ -746,7 +746,7 @@ fn highlight_def(db: &RootDatabase, def: Definition) -> Highlight {
746 if func.is_unsafe(db) { 746 if func.is_unsafe(db) {
747 h |= HighlightModifier::Unsafe; 747 h |= HighlightModifier::Unsafe;
748 } 748 }
749 if func.is_associated(db) { 749 if func.is_assoc_item(db) && func.self_param(db).is_none() {
750 h |= HighlightModifier::Static; 750 h |= HighlightModifier::Static;
751 } 751 }
752 return h; 752 return h;