Skip to content

Compilation Error in Java #98

Description

@newbie-gk

Hi,
I'm getting these warnings\error when trying to use koma in a java project.

Warning:java: unknown enum constant kotlin.annotation.AnnotationRetention.BINARY
reason: class file for kotlin.annotation.AnnotationRetention not found
Warning:java: unknown enum constant kotlin.annotation.AnnotationTarget.CLASS
reason: class file for kotlin.annotation.AnnotationTarget not found
Warning:java: unknown enum constant kotlin.annotation.AnnotationTarget.FUNCTION
Warning:java: unknown enum constant kotlin.annotation.AnnotationTarget.PROPERTY
Warning:java: unknown enum constant kotlin.annotation.AnnotationTarget.CONSTRUCTOR
Warning:java: unknown enum constant kotlin.annotation.AnnotationTarget.PROPERTY_GETTER
Warning:java: unknown enum constant kotlin.annotation.AnnotationTarget.PROPERTY_SETTER
Error:(74, 16) java: cannot access kotlin.jvm.functions.Function0
class file for kotlin.jvm.functions.Function0 not found

I'm new to Kotlin / using kotlin in Java, not sure if I'm doing something wrong. Any guidance is greatly appreciated.

I built the library using the ./gradlew buildJvm and added the jar files to my project library.

As for using it in java:
import koma.Koma; <-- this seems fine, no import errors

double[][] distanceMatrix = function assigning value to distanceMatrix

Matrix m = Koma.create(distanceMatrix); <-- this is where the Compilation Error happened

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions