haskell-tree-sitter
haskell-tree-sitter copied to clipboard
Queries
I think Queries are working properly.
This is the first time did anything with the FFI, so there are a few things I am unsure about.
I moved Struct into a new module to use it in Query. This should maybe be moved into an Internal directory.
I don't fully understand Storable, so I left some things unfinished there. Particularly TSQueryError which is currently just an Int.
While testing a bridged ts_node_string before seeing there was already an open issue. I also made a helper to call it on a Node.
Finally, I ran clang format (automatically) with WebKit styling on bridge.c. If it was using a particular formatter I can revert that.
Hi @Gauteab, thanks for the contribution!
Finally, I ran clang format (automatically) with WebKit styling on bridge.c. If it was using a particular formatter I can revert that.
Yes, please revert the styling changes, since they're not a substantive part of the PR. It's much harder for us to review if the diff contains a bunch of cosmetic changes to unrelated parts of the file.