aboutsummaryrefslogtreecommitdiffstats
path: root/queries/ruby/highlights.scm
diff options
context:
space:
mode:
Diffstat (limited to 'queries/ruby/highlights.scm')
-rw-r--r--queries/ruby/highlights.scm11
1 files changed, 8 insertions, 3 deletions
diff --git a/queries/ruby/highlights.scm b/queries/ruby/highlights.scm
index 83cffffd4..738f9c9f8 100644
--- a/queries/ruby/highlights.scm
+++ b/queries/ruby/highlights.scm
@@ -71,9 +71,6 @@
"ensure"
] @keyword.exception
-((identifier) @keyword.exception
- (#any-of? @keyword.exception "fail" "raise"))
-
; Function calls
"defined?" @function
@@ -127,6 +124,14 @@
(#any-of? @constant.builtin
"__callee__" "__dir__" "__id__" "__method__" "__send__" "__ENCODING__" "__FILE__" "__LINE__"))
+((identifier) @function.builtin
+ (#any-of? @function.builtin
+ "include" "extend" "prepend" "attr_reader" "attr_writer" "attr_accessor" "module_function"
+ "refine" "using"))
+
+((identifier) @keyword.exception
+ (#any-of? @keyword.exception "raise" "fail" "catch" "throw"))
+
((constant) @type
(#not-lua-match? @type "^[A-Z0-9_]+$"))