Skip to content

Unresolved reference: AntlrKotlinTask with gradle 9.0 #205

@bingo-soft

Description

@bingo-soft

I could not find any working build.gradle.kts, so I just tried this:

plugins {
    kotlin("jvm") version "2.0.21"
    id("com.vanniktech.maven.publish") version "0.28.0"
    id("antlr")
    id("com.strumenta.antlr-kotlin") version "1.0.0"
}

group = "com.example"
version = "unspecified"

repositories {
    mavenCentral()
}

dependencies {
    antlr("org.antlr:antlr4:4.13.2")
    implementation("com.strumenta:antlr-kotlin-runtime:1.0.0")
}

val generateGrammarSource by tasks.registering(AntlrKotlinTask::class) {
    //...
}

And that gives me an error:

val generateGrammarSource by tasks.registering(AntlrKotlinTask::class) {
                                                          ^ Unresolved reference: AntlrKotlinTask

Do not know how to fix it. Thanks in advance!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions