Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

style: try fixing clippy warning #2341

Merged
merged 1 commit into from
Mar 22, 2024
Merged

Conversation

SteveLauC
Copy link
Member

@SteveLauC SteveLauC commented Mar 22, 2024

What does this PR do

Fix the below clippy warning:

error: useless use of `vec!`
    --> test/sys/test_socket.rs:2410:19
     |
2410 |     let mut iov = vec![[IoSliceMut::new(&mut buffer)]];
     |                   ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: you can use an array directly: `[[IoSliceMut::new(&mut buffer)]]`
     |
     = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_vec
     = note: `-D clippy::useless-vec` implied by `-D warnings`
     = help: to override `-D warnings` add `#[allow(clippy::useless_vec)]`

Checklist:

  • I have read CONTRIBUTING.md
  • I have written necessary tests and rustdoc comments
  • A change log has been added if this PR modifies nix's API

@SteveLauC SteveLauC marked this pull request as ready for review March 22, 2024 00:28
@SteveLauC SteveLauC added this pull request to the merge queue Mar 22, 2024
Merged via the queue into nix-rust:master with commit 01cd697 Mar 22, 2024
34 checks passed
@SteveLauC SteveLauC deleted the style/clippy branch March 22, 2024 01:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant