https://kotlinlang.org logo
Title
h

Hullaballoonatic

10/19/2018, 2:56 AM
i so desperately want short notation for enum constants in kotlin. the preceding class names are just so verbose and i love writing kotlin like prose. if the context is enough to let the compiler know what enum class is being referred to, then it should be enough for readers, too. and even if not, the short notation could be optional. that probably takes quite a bit of effort from kotlin team to implement, though, and it's not as important as some of the really key features they added in 1.3
d

dave08

10/19/2018, 2:59 AM
Just
import EnumName.*
where you use it a lot... a bit more work, but clearer in your code sometimes...
✍️ 1
e

elizarov

10/19/2018, 4:48 AM
Not much work. Just alt+enter and there is a quick fix to add import.