{"action":"created","issue":{"url":"https://api.github.com/repos/tree-sitter/haskell-tree-sitter/issues/72","repository_url":"https://api.github.com/repos/tree-sitter/haskell-tree-sitter","labels_url":"https://api.github.com/repos/tree-sitter/haskell-tree-sitter/issues/72/labels{/name}","comments_url":"https://api.github.com/repos/tree-sitter/haskell-tree-sitter/issues/72/comments","events_url":"https://api.github.com/repos/tree-sitter/haskell-tree-sitter/issues/72/events","html_url":"https://github.com/tree-sitter/haskell-tree-sitter/issues/72","id":377184215,"node_id":"MDU6SXNzdWUzNzcxODQyMTU=","number":72,"title":"Usage example needed","user":{"login":"clojj","id":4367963,"node_id":"MDQ6VXNlcjQzNjc5NjM=","avatar_url":"https://avatars3.githubusercontent.com/u/4367963?v=4","gravatar_id":"","url":"https://api.github.com/users/clojj","html_url":"https://github.com/clojj","followers_url":"https://api.github.com/users/clojj/followers","following_url":"https://api.github.com/users/clojj/following{/other_user}","gists_url":"https://api.github.com/users/clojj/gists{/gist_id}","starred_url":"https://api.github.com/users/clojj/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/clojj/subscriptions","organizations_url":"https://api.github.com/users/clojj/orgs","repos_url":"https://api.github.com/users/clojj/repos","events_url":"https://api.github.com/users/clojj/events{/privacy}","received_events_url":"https://api.github.com/users/clojj/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":1,"created_at":"2018-11-04T19:12:36Z","updated_at":"2018-11-04T23:05:35Z","closed_at":null,"author_association":"NONE","body":"https://tree-sitter.github.io/tree-sitter/using-parsers#editing\r\n\r\nHow to do this with this haskell binding is not obvious.\r\nIt would be great to have a Haskell example, showing how to use this binding:\r\n1 parse and get the tree of nodes\r\n2 edit and reparse\r\n\r\nAlso....\r\nts_node_edit and other API functions are not yet in the FFI binding.... not needed ?\r\nor is a pull request welcome ?"},"comment":{"url":"https://api.github.com/repos/tree-sitter/haskell-tree-sitter/issues/comments/435717146","html_url":"https://github.com/tree-sitter/haskell-tree-sitter/issues/72#issuecomment-435717146","issue_url":"https://api.github.com/repos/tree-sitter/haskell-tree-sitter/issues/72","id":435717146,"node_id":"MDEyOklzc3VlQ29tbWVudDQzNTcxNzE0Ng==","user":{"login":"clojj","id":4367963,"node_id":"MDQ6VXNlcjQzNjc5NjM=","avatar_url":"https://avatars3.githubusercontent.com/u/4367963?v=4","gravatar_id":"","url":"https://api.github.com/users/clojj","html_url":"https://github.com/clojj","followers_url":"https://api.github.com/users/clojj/followers","following_url":"https://api.github.com/users/clojj/following{/other_user}","gists_url":"https://api.github.com/users/clojj/gists{/gist_id}","starred_url":"https://api.github.com/users/clojj/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/clojj/subscriptions","organizations_url":"https://api.github.com/users/clojj/orgs","repos_url":"https://api.github.com/users/clojj/repos","events_url":"https://api.github.com/users/clojj/events{/privacy}","received_events_url":"https://api.github.com/users/clojj/received_events","type":"User","site_admin":false},"created_at":"2018-11-04T23:05:35Z","updated_at":"2018-11-04T23:05:35Z","author_association":"NONE","body":"ok, I have pushed an example\r\nhttps://github.com/clojj/hs-tree-sitter-test/blob/master/app/Main.hs\r\n\r\nIn the long run, I'd like to parse->edit->reparse. So I will give extending the FFI a shot at some point.\r\nFor now, I think I'll just do some work on that higher-level data structure.\r\n`data Tree a = Node {rootLabel :: a, subForest :: Forest a}`\r\n...that should do it I think\r\n\r\nhere's my example\r\n![test](https://user-images.githubusercontent.com/4367963/47971080-eca44800-e08d-11e8-82e1-85624f6bc2d2.png)\r\n"}}
{"actor":{"display_login":"clojj"}}