Update crates/ide/src/syntax_highlighting/highlight.rs

Co-authored-by: Aleksey Kladov <aleksey.kladov@gmail.com>
This commit is contained in:
Jake 2021-08-03 09:54:27 -07:00 committed by GitHub
parent 0eb1afdcb7
commit 28b6a30752
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -489,7 +489,8 @@ fn highlight_def(db: &RootDatabase, krate: Option<hir::Crate>, def: Definition)
let ty = local.ty(db);
if local.is_mut(db) || ty.is_mutable_reference() {
h |= HlMod::Mutable;
} else if local.is_ref(db) || ty.is_reference() {
}
if local.is_ref(db) || ty.is_reference() {
h |= HlMod::Reference;
}
if ty.as_callable(db).is_some() || ty.impls_fnonce(db) {