/// Frees a previously-made memory allocation in Pdfium's WASM memory heap.
Frees a previously-made memory allocation in Pdfium's WASM memory heap.
Frees a previously - made memory allocation in Pdfium ' s WASM memory heap .
fn free(&self, ptr: usize) {
        if ptr > 0 {
            let result = self
                .free_js_fn
                .as_ref()
                .unwrap()
                .call1(&JsValue::null(), &JsValue::from_f64(ptr as f64));
            if let Some(err) = result.err() {
                log::error!(
                "pdfium-render::PdfiumRenderWasmState::free(): call to Module._free() failed: {:#?}",
                err
            );
                panic!()
            }
        }
    }
fn free ( & self , ptr : usize ) { if ptr > 0 { let result = self . free_js_fn . as_ref ( ) . unwrap ( ) . call1 ( & JsValue :: null ( ) , & JsValue :: from_f64 ( ptr as f64 ) ) ; if let Some ( err ) = result . err ( ) { log :: error ! ( " " err ) ; panic ! ( ) } } }
Frees a previously-made memory allocation in Pdfium's WASM memory heap.
Frees a previously - made memory allocation in Pdfium ' s WASM memory heap .
&self
ptr
usize