We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent d6f37c6 commit 52fa020Copy full SHA for 52fa020
src/librustc_parse/parser/ty.rs
@@ -390,7 +390,7 @@ impl<'a> Parser<'a> {
390
negative_bounds: Vec<Span>,
391
) {
392
let negative_bounds_len = negative_bounds.len();
393
- let last_span = *negative_bounds.last().unwrap();
+ let last_span = *negative_bounds.last().expect("no negative bounds, but still error?");
394
let mut err = self.struct_span_err(
395
negative_bounds,
396
"negative bounds are not supported",
0 commit comments