Начиная с Rust 1.40, вы также можете использовать Option::as_deref . maybe_string.as_deref().unwrap_or("none");.
確定! 回上一頁