diff --git a/library/core/src/option.rs b/library/core/src/option.rs index 77619d61d9f..cfa77f39f57 100644 --- a/library/core/src/option.rs +++ b/library/core/src/option.rs @@ -715,6 +715,7 @@ impl Option { /// _expect_ the `Option` should be `Some`. /// /// ```should_panic + /// # let slice: &[u8] = &[]; /// let item = slice.get(0) /// .expect("slice should not be empty"); /// ```