Describe the bug
A class Bug is in package a and b. a.Bug contains a property of type: b.Bug.
|
-- a
--- Bug.kt
-- b
---- Bug.kt
To Reproduce
package a
import b.Bug
import kotlinx.serialization.Serializable
@Serializable
data class Bug(val id: Long = 0) {
val d get() = Bug()
}
// ------
package b
class Bug
or github project
Expected behavior
a serializable class, valid to JSON "{"id": 0}"
Environment
- Kotlin version: 1.3.61
- Library version: 0.14
- Kotlin platforms: JVM
- Gradle version: 5.2.1
- IDE version: IntelliJ IDEA 2019.3.2
- Other relevant context: -