https://kotlinlang.org logo
Title
r

rnett

01/14/2019, 2:41 AM
I'm trying to instantiate a java class
class Builder<T extends Builder<T>>
. In java, you just use
new SpaceToBatchLayer.Builder()
, however, Kotlin forces you to specify the type argument. Is there a way around this for interop w/ java?
s

Shawn

01/14/2019, 4:18 AM
pretty sure Kotlin doesn’t force you to specify the type argument if it can be inferred
can you post a quick MCVE to see if there’s anything funky about your situation?
c

Czar

01/14/2019, 7:39 AM
This is a known problem. You can look at the issue on the tracker, there are a couple of work-arounds there too: https://youtrack.jetbrains.com/issue/KT-17186