From 4fd5248749202e0578d719bc5480171a85358836 Mon Sep 17 00:00:00 2001 From: Aramis Razzaghipour Date: Sun, 23 May 2021 23:45:26 +1000 Subject: Add highlighting of items from other crates --- crates/ide/src/syntax_highlighting/tags.rs | 4 ++++ 1 file changed, 4 insertions(+) (limited to 'crates/ide/src/syntax_highlighting/tags.rs') diff --git a/crates/ide/src/syntax_highlighting/tags.rs b/crates/ide/src/syntax_highlighting/tags.rs index 27473a2f9..755599cba 100644 --- a/crates/ide/src/syntax_highlighting/tags.rs +++ b/crates/ide/src/syntax_highlighting/tags.rs @@ -67,6 +67,8 @@ pub enum HlMod { Trait, /// Used with keywords like `async` and `await`. Async, + /// Used for items from other crates. + Foreign, // Keep this last! /// Used for unsafe functions, unsafe traits, mutable statics, union accesses and unsafe operations. Unsafe, @@ -189,6 +191,7 @@ impl HlMod { HlMod::Static, HlMod::Trait, HlMod::Async, + HlMod::Foreign, HlMod::Unsafe, ]; @@ -207,6 +210,7 @@ impl HlMod { HlMod::Static => "static", HlMod::Trait => "trait", HlMod::Async => "async", + HlMod::Foreign => "foreign", HlMod::Unsafe => "unsafe", } } -- cgit v1.2.3