Skip to content

Commit 6833183

Browse files
committed
Unsafe traits
1 parent a5f2b16 commit 6833183

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

crates/ra_ide/src/display/short_label.rs

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,11 @@ impl ShortLabel for ast::EnumDef {
3333

3434
impl ShortLabel for ast::TraitDef {
3535
fn short_label(&self) -> Option<String> {
36-
short_label_from_node(self, "trait ")
36+
if self.unsafe_token().is_some() {
37+
short_label_from_node(self, "unsafe trait ")
38+
} else {
39+
short_label_from_node(self, "trait ")
40+
}
3741
}
3842
}
3943

0 commit comments

Comments
 (0)