diff options
author | bors[bot] <26634292+bors[bot]@users.noreply.github.com> | 2021-05-25 03:30:47 +0100 |
---|---|---|
committer | GitHub <[email protected]> | 2021-05-25 03:30:47 +0100 |
commit | 8b049ec393230e4b9fea3022a3ebf34e2af5395d (patch) | |
tree | d75b9290e907898027eab2e723ed1c0040e43e4e /crates/rust-analyzer/src/to_proto.rs | |
parent | 6d473c0a8f6acecbae680b69528b3f88a31dc5fc (diff) | |
parent | d75277b66b07e3fa4fed5088b92c6f65b2de8fe9 (diff) |
Merge #8942
8942: Add `library` semantic token modifier to items from other crates r=arzg a=arzg
Closes #5772.
A lot of code here is pretty repetitive; please let me know if you have any ideas how to improve it, or whether it’s fine as-is.
Side-note: How can I add tests for this? I don’t see a way for the test Rust code in `test_highlighting` to reference other crates to observe the new behaviour.
Co-authored-by: Aramis Razzaghipour <[email protected]>
Diffstat (limited to 'crates/rust-analyzer/src/to_proto.rs')
-rw-r--r-- | crates/rust-analyzer/src/to_proto.rs | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/crates/rust-analyzer/src/to_proto.rs b/crates/rust-analyzer/src/to_proto.rs index 410384ae5..ca9513928 100644 --- a/crates/rust-analyzer/src/to_proto.rs +++ b/crates/rust-analyzer/src/to_proto.rs | |||
@@ -504,6 +504,7 @@ fn semantic_token_type_and_modifiers( | |||
504 | HlMod::Mutable => semantic_tokens::MUTABLE, | 504 | HlMod::Mutable => semantic_tokens::MUTABLE, |
505 | HlMod::Consuming => semantic_tokens::CONSUMING, | 505 | HlMod::Consuming => semantic_tokens::CONSUMING, |
506 | HlMod::Async => semantic_tokens::ASYNC, | 506 | HlMod::Async => semantic_tokens::ASYNC, |
507 | HlMod::Library => semantic_tokens::LIBRARY, | ||
507 | HlMod::Unsafe => semantic_tokens::UNSAFE, | 508 | HlMod::Unsafe => semantic_tokens::UNSAFE, |
508 | HlMod::Callable => semantic_tokens::CALLABLE, | 509 | HlMod::Callable => semantic_tokens::CALLABLE, |
509 | HlMod::Static => lsp_types::SemanticTokenModifier::STATIC, | 510 | HlMod::Static => lsp_types::SemanticTokenModifier::STATIC, |