aboutsummaryrefslogtreecommitdiff
path: root/runtime
diff options
context:
space:
mode:
authorCorey Powell2021-06-01 19:44:03 +0000
committerIvan Tham2021-06-04 17:17:44 +0000
commit01dd7b570a692ca59d34c74806e7fcdd48e60b21 (patch)
treededd6e959d5c1a8981dc65eb3952068abd7bf6d6 /runtime
parentf3a243c6cbeeeeec4ccafc813d66df7a0f5dd1a8 (diff)
Restored haskell syntax
It seems to work
Diffstat (limited to 'runtime')
-rw-r--r--runtime/queries/haskell/highlights.scm43
-rw-r--r--runtime/queries/haskell/locals.scm4
2 files changed, 47 insertions, 0 deletions
diff --git a/runtime/queries/haskell/highlights.scm b/runtime/queries/haskell/highlights.scm
new file mode 100644
index 00000000..ecaa2d2c
--- /dev/null
+++ b/runtime/queries/haskell/highlights.scm
@@ -0,0 +1,43 @@
+(variable) @variable
+(operator) @operator
+(exp_name (constructor) @constructor)
+(constructor_operator) @operator
+(module) @module_name
+(type) @type
+(type) @class
+(constructor) @constructor
+(pragma) @pragma
+(comment) @comment
+(signature name: (variable) @fun_type_name)
+(function name: (variable) @fun_name)
+(constraint class: (class_name (type)) @class)
+(class (class_head class: (class_name (type)) @class))
+(instance (instance_head class: (class_name (type)) @class))
+(integer) @literal
+(exp_literal (float)) @literal
+(char) @literal
+(con_unit) @literal
+(con_list) @literal
+(tycon_arrow) @operator
+(where) @keyword
+"module" @keyword
+"let" @keyword
+"in" @keyword
+"class" @keyword
+"instance" @keyword
+"data" @keyword
+"newtype" @keyword
+"family" @keyword
+"type" @keyword
+"import" @keyword
+"qualified" @keyword
+"as" @keyword
+"deriving" @keyword
+"via" @keyword
+"stock" @keyword
+"anyclass" @keyword
+"do" @keyword
+"mdo" @keyword
+"rec" @keyword
+"(" @paren
+")" @paren
diff --git a/runtime/queries/haskell/locals.scm b/runtime/queries/haskell/locals.scm
new file mode 100644
index 00000000..ad67fe43
--- /dev/null
+++ b/runtime/queries/haskell/locals.scm
@@ -0,0 +1,4 @@
+(signature name: (variable)) @local.definition
+(function name: (variable)) @local.definition
+(pat_name (variable)) @local.definition
+(exp_name (variable)) @local.reference