Add error() function to interpreter test helper sources

To compile standard library code that uses error()
This commit is contained in:
Ilya Gorbunov
2022-06-24 06:47:47 +03:00
committed by Space
parent 227953a267
commit 7ab2f1493c
+2
View File
@@ -41,3 +41,5 @@ public inline fun repeat(times: Int, action: (Int) -> Unit) {
action(index)
}
}
public inline fun error(message: Any): Nothing = throw IllegalStateException(message.toString())