py-tree-sitter icon indicating copy to clipboard operation
py-tree-sitter copied to clipboard

Python bindings to the Tree-sitter parsing library

Results 56 py-tree-sitter issues
Sort by recently updated
recently updated
newest added

> @CamilleTeruel @maxbrunsfeld At least currently, according to: http://tree-sitter.github.io/tree-sitter/using-parsers#other-tree-operations > > > You can initialize a cursor from any node: > > > > TSTreeCursor ts_tree_cursor_new(TSNode); > > Also according...

documentation

I've installed py-tree-sitter, but something seems wrong; when trying to import `Parser`, I seem to be told it has no definition (which, among other things, means that in VSCode, autocomplete...

Hi, there! I want to create a script that can automatically modify source code using tree-sitter After I've made changes to the code, I can update the tree (by Tree.edit(...))....

For example if we define `field('var_name', $.identifier);` in gramma.js. How can I get the name 'var_name' from an identifier node object? There is a property `is_named` to indicate whether current...

I am using `tree_sitter==0.19.0` and I am not able to parse `swift`, `verilog`, and `agda` code. I cloned the grammars and installed the newest bindings. Is there anything I can...

Hi, there! I am facing a problem where I need to extract the user-defined identifiers from the source code snippets in multiple programming languages. User-defined identifiers (UIDs) here refer to...

I am currently using the following method to walk the tree: ```python def traverse(tree): def _traverse(node): print_node(node) for child in node.children: _traverse(child) _traverse(tree.root_node) ``` How could someone do the same...

Can tree-sitter support obtaining the argument type of callee function? I can use query mechanism to obtain the method_invocation Node, while I have no idea how to know the argument...

Hi, I'm trying to create a tree traversal using the cursor. The cursor should print the nodes as the recursive method in this other issue (https://github.com/tree-sitter/py-tree-sitter/issues/5). However, the recursive implementation...