diff options
author | Alex Orlenko <zxteam@protonmail.com> | 2021-06-21 03:25:21 +0100 |
---|---|---|
committer | Alex Orlenko <zxteam@protonmail.com> | 2021-06-21 03:25:21 +0100 |
commit | 8d474bbf8d3d6c662921a8c308eb901a6ca422c2 (patch) | |
tree | 2e1935107632dd6fa42ff80c8ae0a159435fce61 /src/scope.rs | |
parent | 9e3b0ecc1ea9083a8eb9961276a15efd985fbe33 (diff) | |
download | mlua-8d474bbf8d3d6c662921a8c308eb901a6ca422c2.zip |
Fix clippy warning
Diffstat (limited to 'src/scope.rs')
-rw-r--r-- | src/scope.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/scope.rs b/src/scope.rs index 33a9c1b..6467e15 100644 --- a/src/scope.rs +++ b/src/scope.rs @@ -392,7 +392,7 @@ impl<'lua, 'scope> Scope<'lua, 'scope> { let mt_id = ffi::lua_topointer(lua.state, -1); // Write userdata just before attaching metatable with `__gc` metamethod - ptr::write(data_ptr as _, UserDataCell::new(data.clone())); + ptr::write(data_ptr as _, UserDataCell::new(data)); ffi::lua_setmetatable(lua.state, -2); let ud = AnyUserData(lua.pop_ref()); lua.register_userdata_metatable(mt_id as isize); |