[JS IR] stdlib: Use Nothing in return type of THROW helpers
Backend generated calls to those helpers inside expression which resuleted in invalid type casts in IR (in dead code).
This commit is contained in:
@@ -12,12 +12,12 @@ internal fun throwUninitializedPropertyAccessException(name: String): Nothing =
|
||||
internal fun noWhenBranchMatchedException(): Nothing = throw NoWhenBranchMatchedException()
|
||||
|
||||
|
||||
fun THROW_ISE() {
|
||||
fun THROW_ISE(): Nothing {
|
||||
throw IllegalStateException()
|
||||
}
|
||||
fun THROW_CCE() {
|
||||
fun THROW_CCE(): Nothing {
|
||||
throw ClassCastException()
|
||||
}
|
||||
fun THROW_NPE() {
|
||||
fun THROW_NPE(): Nothing {
|
||||
throw NullPointerException()
|
||||
}
|
||||
Reference in New Issue
Block a user