I'm trying to access the children of a sealed clas...
# announcements
h
I'm trying to access the children of a sealed class via a typealias, but it fails with
Unresolved reference
. Is that generally impossible?
Copy code
sealed class LoginScreenAction {
  object NameEntered : LoginScreenAction()
  object SubmitClicked : LoginScreenAction()
}

private typealias Action = LoginScreenAction

fun main() {
  println("My action is: ${Action.NameEntered}")
}
m
Looks like it’s planned for Kotlin 1.3+ https://youtrack.jetbrains.com/issue/KT-15298
h
Oh, great, thanks!