File tree 1 file changed +8
-2
lines changed
tests/ui-toml/unwrap_used
1 file changed +8
-2
lines changed Original file line number Diff line number Diff line change @@ -188,10 +188,16 @@ LL | let _ = some_vec.get_mut(0..1).unwrap().to_vec();
188
188
= help: if you don't want to handle the `None` case gracefully, consider using `expect()` to provide a better panic message
189
189
190
190
error: called `.get().unwrap()` on a slice. Using `[]` is more clear and more concise
191
- --> $DIR/unwrap_used.rs:84:17
191
+ --> $DIR/unwrap_used.rs:72:13
192
+ |
193
+ LL | let _ = boxed_slice.get(1).unwrap();
194
+ | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try this: `&boxed_slice[1]`
195
+
196
+ error: called `.get().unwrap()` on a slice. Using `[]` is more clear and more concise
197
+ --> $DIR/unwrap_used.rs:90:17
192
198
|
193
199
LL | let _ = Box::new([0]).get(1).unwrap();
194
200
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try this: `&Box::new([0])[1]`
195
201
196
- error: aborting due to 27 previous errors
202
+ error: aborting due to 28 previous errors
197
203
You can’t perform that action at this time.
0 commit comments