From e2b8c0ed29ff6ea99f75fe9c03bade29cd6aa644 Mon Sep 17 00:00:00 2001 From: DBotThePony Date: Mon, 16 Dec 2024 20:20:51 +0700 Subject: [PATCH] Fix Lua errors not inheriting RuntimeException --- .../kotlin/ru/dbotthepony/kstarbound/lua/Errors.kt | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/main/kotlin/ru/dbotthepony/kstarbound/lua/Errors.kt b/src/main/kotlin/ru/dbotthepony/kstarbound/lua/Errors.kt index ca5638b9..32dc749f 100644 --- a/src/main/kotlin/ru/dbotthepony/kstarbound/lua/Errors.kt +++ b/src/main/kotlin/ru/dbotthepony/kstarbound/lua/Errors.kt @@ -15,11 +15,11 @@ const val LUA_ERRSYNTAX = 3 const val LUA_ERRMEM = 4 const val LUA_ERRERR = 5 -class InvalidLuaSyntaxException(message: String? = null, cause: Throwable? = null) : Throwable(message, cause) -class LuaMemoryAllocException(message: String? = null, cause: Throwable? = null) : Throwable(message, cause) -class LuaGCException(message: String? = null, cause: Throwable? = null) : Throwable(message, cause) -class LuaException(message: String? = null, cause: Throwable? = null) : Throwable(message, cause) -class LuaRuntimeException(message: String? = null, cause: Throwable? = null) : Throwable(message, cause) +class InvalidLuaSyntaxException(message: String? = null, cause: Throwable? = null) : RuntimeException(message, cause) +class LuaMemoryAllocException(message: String? = null, cause: Throwable? = null) : RuntimeException(message, cause) +class LuaGCException(message: String? = null, cause: Throwable? = null) : RuntimeException(message, cause) +class LuaException(message: String? = null, cause: Throwable? = null) : RuntimeException(message, cause) +class LuaRuntimeException(message: String? = null, cause: Throwable? = null) : RuntimeException(message, cause) fun throwPcallError(code: Int) { when (code) {