aboutsummaryrefslogtreecommitdiff
path: root/crates/ra_ide/src/syntax_highlighting.rs
diff options
context:
space:
mode:
authorbors[bot] <26634292+bors[bot]@users.noreply.github.com>2019-12-07 19:26:33 +0000
committerGitHub <[email protected]>2019-12-07 19:26:33 +0000
commit971df306ada43f6150e12a143873f680e104a866 (patch)
tree913c24e889f3db8044b4b9f11bc3969e7eb02e34 /crates/ra_ide/src/syntax_highlighting.rs
parenta3eb8787452a04400784ba8fed38303232595695 (diff)
parent88c5b1282a5770097c6c768b24bedfc3a6944e08 (diff)
Merge #2494
2494: Get the right analyzer for impls r=matklad a=matklad Co-authored-by: Aleksey Kladov <[email protected]>
Diffstat (limited to 'crates/ra_ide/src/syntax_highlighting.rs')
-rw-r--r--crates/ra_ide/src/syntax_highlighting.rs12
1 files changed, 10 insertions, 2 deletions
diff --git a/crates/ra_ide/src/syntax_highlighting.rs b/crates/ra_ide/src/syntax_highlighting.rs
index e6a79541f..7ecb1a027 100644
--- a/crates/ra_ide/src/syntax_highlighting.rs
+++ b/crates/ra_ide/src/syntax_highlighting.rs
@@ -225,8 +225,7 @@ fn highlight_name(db: &RootDatabase, name_kind: NameKind) -> &'static str {
225 Def(hir::ModuleDef::Trait(_)) => "type", 225 Def(hir::ModuleDef::Trait(_)) => "type",
226 Def(hir::ModuleDef::TypeAlias(_)) => "type", 226 Def(hir::ModuleDef::TypeAlias(_)) => "type",
227 Def(hir::ModuleDef::BuiltinType(_)) => "type", 227 Def(hir::ModuleDef::BuiltinType(_)) => "type",
228 SelfType(_) => "type", 228 SelfType(_) | TypeParam(_) => "type",
229 GenericParam(_) => "type",
230 Local(local) => { 229 Local(local) => {
231 if local.is_mut(db) { 230 if local.is_mut(db) {
232 "variable.mut" 231 "variable.mut"
@@ -255,6 +254,7 @@ pre { color: #DCDCCC; background: #3F3F3F; font-size: 22px; padd
255.parameter { color: #94BFF3; } 254.parameter { color: #94BFF3; }
256.builtin { color: #DD6718; } 255.builtin { color: #DD6718; }
257.text { color: #DCDCCC; } 256.text { color: #DCDCCC; }
257.type { color: #7CB8BB; }
258.attribute { color: #94BFF3; } 258.attribute { color: #94BFF3; }
259.literal { color: #BFEBBF; } 259.literal { color: #BFEBBF; }
260.macro { color: #94BFF3; } 260.macro { color: #94BFF3; }
@@ -303,6 +303,14 @@ fn main() {
303 303
304 y; 304 y;
305} 305}
306
307enum E<X> {
308 V(X)
309}
310
311impl<X> E<X> {
312 fn new<T>() -> E<T> {}
313}
306"# 314"#
307 .trim(), 315 .trim(),
308 ); 316 );