Fix latest clippy warnings (#3049)

This commit is contained in:
Jonathan Turner
2021-02-12 23:13:14 +13:00
committed by GitHub
parent 041086d22a
commit 5481db4079
213 changed files with 334 additions and 375 deletions

View File

@ -564,9 +564,7 @@ impl ShellError {
diag.message = format!("Missing property (for {})", subpath.item);
} else {
let subpath = Label::primary(0, subpath.span).with_message(subpath.item);
let mut labels = vec![];
labels.push(subpath);
let mut labels = vec![subpath];
if expr.span != Span::unknown() {
let expr = Label::primary(0, expr.span).with_message(expr.item);