We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
ref
1 parent e5b8c11 commit 4ea1a19Copy full SHA for 4ea1a19
src/libcore/option.rs
@@ -64,7 +64,7 @@
64
//!
65
//! fn check_optional(optional: Option<Box<i32>>) {
66
//! match optional {
67
-//! Some(ref p) => println!("has value {}", p),
+//! Some(p) => println!("has value {}", p),
68
//! None => println!("has no value"),
69
//! }
70
@@ -83,7 +83,7 @@
83
//! let msg = Some("howdy");
84
85
//! // Take a reference to the contained string
86
-//! if let Some(ref m) = msg {
+//! if let Some(m) = &msg {
87
//! println!("{}", *m);
88
89
0 commit comments