deref function pointer, not sure if this does anything
This commit is contained in:
parent
aa1db9551e
commit
9a03ac199a
@ -403,7 +403,7 @@ impl ClassMethods<'_>{
|
|||||||
/// return self.methods[index] or create the function in the hashmap and then return it
|
/// return self.methods[index] or create the function in the hashmap and then return it
|
||||||
fn get_or_create_function(&mut self,lua:&mlua::Lua,index:&str)->mlua::Result<Option<mlua::Function>>{
|
fn get_or_create_function(&mut self,lua:&mlua::Lua,index:&str)->mlua::Result<Option<mlua::Function>>{
|
||||||
Ok(match self.method_pointers.get_entry(index){
|
Ok(match self.method_pointers.get_entry(index){
|
||||||
Some((&static_index_str,function_pointer))=>Some(
|
Some((&static_index_str,&function_pointer))=>Some(
|
||||||
self.methods.entry(static_index_str)
|
self.methods.entry(static_index_str)
|
||||||
.or_insert(lua.create_function(function_pointer)?)
|
.or_insert(lua.create_function(function_pointer)?)
|
||||||
.clone()
|
.clone()
|
||||||
|
Loading…
Reference in New Issue
Block a user