All Downloads are FREE. Search and download functionalities are using the official Maven repository.

jvmTest.org.luaj.vm2.require.RequireSampleLoadLuaError.kt Maven / Gradle / Ivy

There is a newer version: 4.0.0-alpha-2
Show newest version
package org.luaj.vm2.require

import org.luaj.vm2.LuaValue
import org.luaj.vm2.lib.ZeroArgFunction

/**
 * This should fail while trying to load via
 * "require()" because it throws a LuaError
 *
 */
class RequireSampleLoadLuaError : ZeroArgFunction() {

    override fun call(): LuaValue {
        LuaValue.error("sample-load-lua-error")
        return LuaValue.valueOf("require-sample-load-lua-error")
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy