tree-sitter-scala
tree-sitter-scala copied to clipboard
Scala grammar for tree-sitter
Hi Tree-Sitter-Scala, When parsing the following class the private val lines are not showing up in the tree: ``` class MyClass @Inject()(injectedVar1: Type1, injectedVar2: Type2) { private val VARIABLE =...
From a discussion during #1 : > Now that I'm seeing how much structure there is to type parameters, I think we should tweak their > structure so that there...
Type projections are currently parsed as `infix_types`. I think something like the following might be better. ``` ================================== Type projections ================================== class A { class B } type C =...
Currently a singleton type results in a ``` ================================== Singleton Types ================================== class A { def foobar: this.type = this } --- (compilation_unit (class_definition (identifier) (template_body (function_definition (identifier) (stable_type_identifier (identifier)...
``` object Lambda { def main(args:Array[String]) : Unit {} } ``` Above code gives error ``` (compilation_unit 'tests/scala/dharm.scala' (object_definition name: (identifier 'Lambda') body: (template_body (function_declaration name: (identifier 'main') parameters: (parameters...
``` object Lambda { def main(args:Array[String]) { randomInt() match { case (0, 1) => (zzz:Int, _) => println(zzz) } } } ``` An extra body is added in `case_clause` instead...
Sharing queries for proper indents (also fixes problem descirbed in #173). I'm going to use them for a while and polish before merging cc @keynmol
### Commit of tree-sitter-scala you tested this on b3ac6a5d959d3137e7f3146d4d9f7899872177de ### A code sample showing the error ```scala TypeTreeWithDeferredRefCheck() { () => val tp = qual.tpe; val sym = tp.typeSymbolDirect 1...
The latest release [appears to be 0.20.2](https://github.com/tree-sitter/tree-sitter-scala/releases/tag/v0.20.2) however the latest published package on npm is [0.19.0](https://www.npmjs.com/package/tree-sitter-scala). Is NPM an official release channel for this package? If so could we have...
We're behind on the tree-sitter version, so we should consider bumping the version up for code gen and testing purpose. ## breaking changes in 0.21.0 https://github.com/tree-sitter/tree-sitter/releases/tag/v0.21.0 > - Remove the...