tree-sitter-kotlin
tree-sitter-kotlin copied to clipboard
Kotlin grammar for Tree-sitter
In my pursuits running the Kotlin parser on many open-source repos, I've noticed that a very common we cannot parse is expressions of the form `Foo::bar`. It seems that this...
"parsing" category on crates.io is for low-level/general-purpose tooling for making parsers. Language-specific parsers belong to `parser-implementations` category.
If I include both regular arguments to a function call and a trailing lambda, it gets parsed as two separate function calls instead of one. Example: ```kotlin fun performOperation(x: Int,...
Error message: node:internal/modules/cjs/loader:1452 return process.dlopen(module, path.toNamespacedPath(filename)); ^ Error: dlopen(/Users/jenny.cai/Source/detect-bug-in-code/node_modules/tree-sitter-kotlin/build/Release/tree_sitter_kotlin_binding.node, 0x0001): symbol not found in flat namespace (_tree_sitter_kotlin_external_scanner_create) at Module._extensions..node (node:internal/modules/cjs/loader:1452:18) at Module.load (node:internal/modules/cjs/loader:1197:32) at Module._load (node:internal/modules/cjs/loader:1013:12) at Module.require (node:internal/modules/cjs/loader:1225:19) at...
Expose string_content to the parse tree so that we don't need to manually strip quotes to get the string content.
- Adapt existing bindings to match the upstream ones - Add the new standard bindings introduced upstream - Add (as of yet) non-standard bindings for [ktreesitter](https://github.com/tree-sitter/kotlin-tree-sitter) - Use the official...
I'm very cautious if I have to merge this PR or not. This might be the reason why https://github.com/fwcd/tree-sitter-kotlin/issues/120 is failing too I wanna check how CI treats this first
Currently, we cannot parse programs which have things like: ```kotlin Foo(context).elem = var1 ``` which assigns `var1` to the property `elem` of the object returned by `Foo(context)`. You can see...
Fixes https://github.com/fwcd/tree-sitter-kotlin/issues/153 by using receiver_type. - I'm not too familiar with grammar-writing, so I'm unsure if my fixes here are ideal. - `function_type` has been updated to more closely match...