Skip to content

Commit

Permalink
fix unnecessary vec! lint instances
Browse files Browse the repository at this point in the history
  • Loading branch information
chris-laplante authored and djc committed Aug 25, 2023
1 parent a5a8524 commit 40b40d2
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion examples/cargo.rs
Expand Up @@ -90,7 +90,7 @@ fn main() {
let green_bold = Style::new().green().bold();

// do progress drawing in main thread
let mut processing = vec![None; NUM_CPUS];
let mut processing = [None; NUM_CPUS];
while let Ok((n, krate)) = rx.recv() {
processing[n] = krate;
let crates: Vec<&str> = processing
Expand Down
2 changes: 1 addition & 1 deletion src/iter.rs
Expand Up @@ -334,7 +334,7 @@ mod test {

#[test]
fn it_can_wrap_an_iterator() {
let v = vec![1, 2, 3];
let v = [1, 2, 3];
let wrap = |it: ProgressBarIter<_>| {
assert_eq!(it.map(|x| x * 2).collect::<Vec<_>>(), vec![2, 4, 6]);
};
Expand Down

0 comments on commit 40b40d2

Please sign in to comment.