The method will trigger the panic handler if a cast cannot be made, this is fine when running in lua, but when executed from C++ it aborts the application when building without exceptions.
Suggestion is to have Userdata::get to return a TypeResult<T*> instead of T* (and eventually making TypeResult to hold an error string).