Add support for FnOnce to Closure

This commit is contained in:
Nick Fitzgerald
2019-02-20 10:48:01 -08:00
parent 1299a2086f
commit 2ce57a7fa1
4 changed files with 462 additions and 63 deletions

View File

@ -657,7 +657,9 @@ pub fn throw_val(s: JsValue) -> ! {
///
/// # Example
///
/// ```no_run
/// ```
/// use wasm_bindgen::prelude::*;
///
/// // If the value is `Option::Some` or `Result::Ok`, then we just get the
/// // contained `T` value.
/// let x = Some(42);