kotlinx/ast

Failed to parse typeParameter

arkadiuszpalka opened this issue · 3 comments

I noticed that the library has problem to parse generic type with . dot

File under test:

class SimpleType<V : BaseType.SubType> {

}

failed to parse typeParameter

I'm invoking it like at example:

        kotlinFile.summary(attachRawAst = false)
            .onSuccess { astList ->
                astList.forEach {
                    it.print()
                }
            }.onFailure { errors ->
                errors.forEach(::println)
            }

Library version:

com.github.kotlinx.ast:grammar-kotlin-parser-antlr-kotlin-jvm:75251cf4d8

Hi @arkadiuszpalka,

thank you for reporting, I will fix this.

Hi @arkadiuszpalka,

should be working now, please try com.github.kotlinx.ast:grammar-kotlin-parser-antlr-kotlin-jvm:d88839cab5 for kotlin 1.3 or com.github.kotlinx.ast:grammar-kotlin-parser-antlr-kotlin-jvm:c7dd6bbd54 for kotlin 1.4 (support for kotlin 1.4 is new)

Hi @drieks , thank you for quick fix!

I have checked it in the com.github.kotlinx.ast:grammar-kotlin-parser-antlr-kotlin-jvm:c7dd6bbd54 (kotlin 1.4) and works well