Closed
Description
Kotlin 1.7.20 introduced "Open-ended ranges", see https://youtrack.jetbrains.com/issue/KT-52932.
As a consequence, writing a Kotlin Range
now writes not just the start
and end
properties, but also endExclusive
.
To Reproduce
val mapper: ObjectMapper = ObjectMapper().registerModule(KotlinModule.Builder().build())
println(mapper.writeValueAsString(IntRange(1,3)))
will print out {"start":1,"end":3,"endExclusive":4}
.
Expected behavior
The above code should print out {"start":1,"end":3}
.
Versions
Kotlin: 1.7.20
Jackson-module-kotlin: 2.13.4
Jackson-databind: 2.13.4
Suggested solution
Add @JsonIgnore abstract public fun getEndExclusive(): T
to KotlinMixins.kt