Skip to content

armgit / zed

Public Imported from GitHub
0

Code at the speed of thought – Zed is a high-performance, multiplayer code editor from the creators of Atom and Tree-sitter.

Improve ruby highlighting (#7829)

Thorsten Balled791c4fc106
diff --git a/crates/zed/src/languages/ruby/highlights.scm b/crates/zed/src/languages/ruby/highlights.scm
index 2610cfa1ccf..14703c4ff28 100644
--- a/crates/zed/src/languages/ruby/highlights.scm
+++ b/crates/zed/src/languages/ruby/highlights.scm
@@ -30,8 +30,6 @@
"yield"
] @keyword
-(identifier) @variable
-
((identifier) @keyword
(#match? @keyword "^(private|protected|public)$"))
@@ -54,11 +52,6 @@
; Identifiers
-[
- (class_variable)
- (instance_variable)
-] @property
-
((identifier) @constant.builtin
(#match? @constant.builtin "^__(FILE|LINE|ENCODING)__$"))
@@ -73,11 +66,19 @@
((constant) @constant
(#match? @constant "^[A-Z\\d_]+$"))
+(global_variable) @constant
+
(constant) @type
(self) @variable.special
(super) @variable.special
+[
+ (class_variable)
+ (instance_variable)
+] @variable.member
+
+
; Literals
[