summaryrefslogtreecommitdiff
path: root/src/util.rs
diff options
context:
space:
mode:
authorJonas Schievink <jonasschievink@gmail.com>2017-08-01 19:36:26 +0200
committerJonas Schievink <jonasschievink@gmail.com>2017-08-01 23:23:31 +0200
commit7e250daccecd16ef8dd1401fd1c61dc5c9685509 (patch)
treed9a92e66db14ede49b285d51fbf66b925eb97624 /src/util.rs
parent64ac8b467918191616ad16ad656ffe997ef35e68 (diff)
downloadmlua-7e250daccecd16ef8dd1401fd1c61dc5c9685509.zip
Enhance error messages
Diffstat (limited to 'src/util.rs')
-rw-r--r--src/util.rs5
1 files changed, 1 insertions, 4 deletions
diff --git a/src/util.rs b/src/util.rs
index 2cc56ed..d731df6 100644
--- a/src/util.rs
+++ b/src/util.rs
@@ -501,10 +501,7 @@ pub unsafe fn push_wrapped_error(state: *mut ffi::lua_State, err: Error) {
Ok(1)
} else {
- Err(Error::FromLuaConversionError(
- "internal error: userdata mismatch in Error metamethod"
- .to_owned(),
- ))
+ panic!("internal error: userdata mismatch in Error metamethod");
})
}