diff --git a/examples/source/usertype_call_from_c++.cpp b/examples/source/usertype_call_from_c++.cpp index 55d790c0..5b2c364a 100644 --- a/examples/source/usertype_call_from_c++.cpp +++ b/examples/source/usertype_call_from_c++.cpp @@ -24,7 +24,7 @@ int main(int, char*[]) { }; lua.new_usertype( - "test", "value", &cpp_object::value); + "cpp_object", "value", &cpp_object::value); lua.new_usertype("test", "func", &test::func); lua.script( "function test:lua_func(obj) print('lua_func', " @@ -48,4 +48,4 @@ int main(int, char*[]) { // lua["test"]["lua_func"](cppobj); return 0; -} \ No newline at end of file +}