Hey everyone, I’m integrating Kotlin into a projec...
# android
m
Hey everyone, I’m integrating Kotlin into a project using Java 8, AS 3.0. I intend on removing
@Data
lombok annotations and using Kotlin data classes instead. However, I’m getting
java.lang.ClassNotFoundException: kotlin.jvm.internal.Intrinsics
, which seems to suggest my Kotlin code isn’t being brought into my project. I have in the global `build.gradle`:
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:1.1.2-4"
and in my app module `build.gradle`:
apply plugin: 'kotlin-android'
d
markyc: Are you also including the kotlin stdlib?
m
@dalexander Where do I include that?
d
In your app dependencies, probably looks something like
compile "org.jetbrains.kotlin:kotlin-stdlib:$kotlin_version"
m
@dalexander++ thanks, that seems to be the issue. FWIW: I found this: https://kotlinlang.org/docs/tutorials/kotlin-android.html which I used to integrate Kt into my existing project, but it didn’t mention adding that line. Presumably because the Configure Kotlin quickfix does it for you, but I never got that quickfix suggestion
👍 1