aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAnatol Liu <[email protected]>2020-11-05 04:08:46 +0000
committerAnatol Liu <[email protected]>2020-11-05 07:41:02 +0000
commit14b38e198cbf6413eb52d61671c904014ed6037d (patch)
tree8b88229f3ba599bf93982bf6a99cd347c6af6106
parent771c0d8c083e9c86a309a4380039602817e09fc8 (diff)
Add static semantic token modifier for associated functions with no &self
refactor logic into code_model.rs
-rw-r--r--crates/hir/src/code_model.rs2
1 files changed, 1 insertions, 1 deletions
diff --git a/crates/hir/src/code_model.rs b/crates/hir/src/code_model.rs
index d04de053f..1319eb9cb 100644
--- a/crates/hir/src/code_model.rs
+++ b/crates/hir/src/code_model.rs
@@ -790,7 +790,7 @@ impl Function {
790 790
791 /// whether this function is associated with some trait/impl 791 /// whether this function is associated with some trait/impl
792 pub fn is_associated(self, db: &dyn HirDatabase) -> bool { 792 pub fn is_associated(self, db: &dyn HirDatabase) -> bool {
793 if let Some(_) = self.self_param(db) { 793 if self.self_param(db).is_some() {
794 return false; 794 return false;
795 } 795 }
796 796