on master help sign in
replace module captures with namespace
e4e8a39Michael Davis
runtime/queries/erlang/highlights.scm+5−5
@@ -2,14 +2,14 @@
2; module declaration
2; module declaration
3(attribute
3(attribute
4 name: (atom) @keyword
4 name: (atom) @keyword
5− (arguments (atom) @module)
5+ (arguments (atom) @namespace)
6 (#eq? @keyword "module"))
6 (#eq? @keyword "module"))
7
7
8(attribute
8(attribute
9 name: (atom) @keyword
9 name: (atom) @keyword
10 (arguments
10 (arguments
11 .
11 .
12− (atom) @module)
12+ (atom) @namespace)
13 (#eq? @keyword "import"))
13 (#eq? @keyword "import"))
14
14
15(attribute
15(attribute
@@ -54,15 +54,15 @@
54
54
55(attribute
55(attribute
56 name: (atom) @keyword
56 name: (atom) @keyword
57− module: (atom) @module
58 (#eq? @keyword "(spec|callback)"))
57 (#eq? @keyword "(spec|callback)"))
58+ module: (atom) @namespace
59
59
60; Functions
60; Functions
61(function_clause name: (atom) @function)
61(function_clause name: (atom) @function)
62−(call module: (atom) @module)
62+(call module: (atom) @namespace)
63(call function: (atom) @function)
63(call function: (atom) @function)
64(stab_clause name: (atom) @function)
64(stab_clause name: (atom) @function)
65−(function_capture module: (atom) @module)
65+(function_capture module: (atom) @namespace)
66(function_capture function: (atom) @function)
66(function_capture function: (atom) @function)
67
67
68; Records
68; Records
runtime/queries/heex/highlights.scm+1−1
@@ -55,7 +55,7 @@
55; HEEx components are highlighted as Elixir modules and functions
55; HEEx components are highlighted as Elixir modules and functions
56(component_name
56(component_name
57 [
57 [
58− (module) @module
58+ (module) @namespace
59 (function) @function
59 (function) @function
60 "." @punctuation.delimiter
60 "." @punctuation.delimiter
61 ])
61 ])