Reputation: 110
When I try to use the organize inputs in a Kotlin class, it does not add missing imports like in Java.
Specific case:
data class Foo (
public var fileEncoding: String = StandardCharsets.UTF_8.name()
)
I would have expected that it added the line import java.nio.charset.StandardCharsets
Upvotes: 1
Views: 977
Reputation: 311
Update: since 0.7.0 Kotlin Eclipse plugin supports organize imports.
At present, Kotlin Eclipse plugin does not support "Organize imports" feature: KT-3962. Please feel free to upvote for this issue.
For now, you can try to invoke quick fix action (Ctrl+1) to import StandardCharsets class.
Upvotes: 3