pub fn create_function_mut<'lua, A, R, F>(&'lua self, func: F) -> Result<Function<'lua>>
    where
        A: FromLuaMulti<'lua>,
        R: ToLuaMulti<'lua>,
        F: 'static + MaybeSend + FnMut(&'lua Lua, A) -> Result<R>,
    {
        let func = RefCell::new(func);
        self.create_function(move |lua, args| {
            (*func
                .try_borrow_mut()
                .map_err(|_| Error::RecursiveMutCallback)?)(lua, args)
        })
    }
/// Wraps a Rust mutable closure, creating a callable Lua function handle to it.
///
/// This is a version of [`create_function`] that accepts a FnMut argument. Refer to
/// [`create_function`] for more information about the implementation.
///
/// [`create_function`]: #method.create_function
Wraps a Rust mutable closure, creating a callable Lua function handle to it.
This is a version of [`create_function`] that accepts a FnMut argument. Refer to
[`create_function`] for more information about the implementation.


Wraps a Rust mutable closure creating a callable Lua function handle to it . This is a version of [ ` create_function ` ] that accepts a FnMut argument . Refer to [ ` create_function ` ] for more information about the implementation .
pub fn create_function_mut<'lua, A, R, F>(&'lua self, func: F) -> Result<Function<'lua>>
    where
        A: FromLuaMulti<'lua>,
        R: ToLuaMulti<'lua>,
        F: 'static + MaybeSend + FnMut(&'lua Lua, A) -> Result<R>,
    {
        let func = RefCell::new(func);
        self.create_function(move |lua, args| {
            (*func
                .try_borrow_mut()
                .map_err(|_| Error::RecursiveMutCallback)?)(lua, args)
        })
    }
pub fn create_function_mut < ' lua , A , R , F > ( & ' lua self , func : F ) -> Result < Function < ' lua > > where A : FromLuaMulti < ' lua > , R : ToLuaMulti < ' lua > , F : ' static + MaybeSend + FnMut ( & ' lua Lua , A ) -> Result < R > , { let func = RefCell :: new ( func ) ; self . create_function ( move | lua , args | { ( * func . try_borrow_mut ( ) . map_err ( | _ | Error :: RecursiveMutCallback ) ? ) ( lua , args ) } ) }
Wraps a Rust mutable closure, creating a callable Lua function handle to it.
Wraps a Rust mutable closure creating a callable Lua function handle to it .
&'lua self
func
F
&'lua self
func
F