aboutsummaryrefslogtreecommitdiff
path: root/crates/hir
diff options
context:
space:
mode:
authorbors[bot] <26634292+bors[bot]@users.noreply.github.com>2021-05-23 13:40:14 +0100
committerGitHub <[email protected]>2021-05-23 13:40:14 +0100
commit064ff633f6055ed35022222c89af01d3f9943e3c (patch)
tree395729f98518d6f4ac5996d3cbfd4b65d04a85f1 /crates/hir
parent57eedd906688d6cfa332bd40bca5234043e7293e (diff)
parent4d4dbcfead82eb6af1f4ef781b197a6926788b15 (diff)
Merge #8940
8940: Give ‘unsafe’ semantic token modifier to unsafe traits r=Veykril a=arzg Hi! This is my first pull request that touches rust-analyzer itself beyond a search-and-replace, so please tell me if I should change anything or do anything differently. :) Co-authored-by: Aramis Razzaghipour <[email protected]>
Diffstat (limited to 'crates/hir')
-rw-r--r--crates/hir/src/lib.rs4
1 files changed, 4 insertions, 0 deletions
diff --git a/crates/hir/src/lib.rs b/crates/hir/src/lib.rs
index 800101c91..a7c42ca1e 100644
--- a/crates/hir/src/lib.rs
+++ b/crates/hir/src/lib.rs
@@ -1085,6 +1085,10 @@ impl Trait {
1085 pub fn is_auto(self, db: &dyn HirDatabase) -> bool { 1085 pub fn is_auto(self, db: &dyn HirDatabase) -> bool {
1086 db.trait_data(self.id).is_auto 1086 db.trait_data(self.id).is_auto
1087 } 1087 }
1088
1089 pub fn is_unsafe(&self, db: &dyn HirDatabase) -> bool {
1090 db.trait_data(self.id).is_unsafe
1091 }
1088} 1092}
1089 1093
1090impl HasVisibility for Trait { 1094impl HasVisibility for Trait {