tree-sitter-haskell
tree-sitter-haskell copied to clipboard
Haskell grammar for tree-sitter.
The finally function is highlighted like a language keyword. I would expect "finally" to have the same highlighting as any other function ``` module Test where import Control.Exception (finally) something...
Given the file: ```haskell import System.Process ``` The parse tree is: ``` haskell (0, 0) - (1, 0) import (0, 0) - (0, 21) import (0, 0) - (0, 6)...
GHC with `TemplateHaskell` allows typed quotations and splices, written ``` [|| x ||] ``` and ``` $$(foo bar) ``` or just ``` $$x ``` Looks like the tree-sitter parser currently...
I have a couple of Rust projects which appears to have `tree-sitter-haskell` as a dependency. The builds are failing consistently because they are timing out when the `tree-sitter-haskell` is being...
``` (base) $ pnpm add tree-sitter-haskell node_modules/.pnpm/[email protected]/node_modules/tree-sitter-haskell: Running install script, failed in 12s .../node_modules/tree-sitter-haskell install$ node-gyp rebuild │ gyp info it worked if it ends with ok │ gyp info...
When parsing a function with a where-clause, tree-sitter-haskell groups comments after the where-clause into the decls node, rather than making them top-level comment nodes. For instance, the following code: ```haskell...
an expression like `(+ x) y` is [parsed correctly](https://felixroos.github.io/haskell-tree-sitter-playground/#KCsgeCkgeQ==), whereas `(# x) y` [yields an error](https://felixroos.github.io/haskell-tree-sitter-playground/#KCMgeCkgeQ==). Interestingly, [it works when prefixing a space](https://felixroos.github.io/haskell-tree-sitter-playground/#KCAjIHgpIHk=). I guess this must be a bug?
Given the file: ``` data X = X { a :: !Int } ``` It's parsed as: ``` haskell (0, 0) - (2, 0) adt (0, 0) - (1, 15)...
Some items are seen as `type variable` when they are not, depending on some weird combination of indentation, extension, ... For example, the folliwing: ``` foo :: Int -> Int...
An objectionable file and the treesitter tree: ```haskell a = () -- single 'a' â = () -- single 'a with circumflex' character â = () -- single 'a' with...