Skip to content

rustfmt

rustfmt #200

Triggered via push April 9, 2024 14:07
Status Success
Total duration 8m 11s
Artifacts
Fit to window
Zoom out
Zoom in

Annotations

26 warnings
casting to the same type is unnecessary (`usize` -> `usize`): src/generic_storage/mmap_vec.rs#L133
warning: casting to the same type is unnecessary (`usize` -> `usize`) --> src/generic_storage/mmap_vec.rs:133:30 | 133 | MmapOptions::new(new_file_len as usize) | ^^^^^^^^^^^^^^^^^^^^^ help: try: `new_file_len` | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast = note: `#[warn(clippy::unnecessary_cast)]` implied by `#[warn(clippy::all)]`
unsafe function's docs miss `# Safety` section: src/generic_storage/mmap_vec.rs#L62
warning: unsafe function's docs miss `# Safety` section --> src/generic_storage/mmap_vec.rs:62:5 | 62 | pub unsafe fn new(file: File) -> color_eyre::Result<Self> { | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_safety_doc
unsafe function's docs miss `# Safety` section: src/generic_storage/mmap_vec.rs#L53
warning: unsafe function's docs miss `# Safety` section --> src/generic_storage/mmap_vec.rs:53:5 | 53 | pub unsafe fn restore(file_path: impl AsRef<Path>) -> color_eyre::Result<Self> { | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_safety_doc
unsafe function's docs miss `# Safety` section: src/generic_storage/mmap_vec.rs#L40
warning: unsafe function's docs miss `# Safety` section --> src/generic_storage/mmap_vec.rs:40:5 | 40 | pub unsafe fn create(file: File, initial_capacity: usize) -> color_eyre::Result<Self> { | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_safety_doc
unsafe function's docs miss `# Safety` section: src/generic_storage/mmap_vec.rs#L22
warning: unsafe function's docs miss `# Safety` section --> src/generic_storage/mmap_vec.rs:22:5 | 22 | / pub unsafe fn open_create( 23 | | file_path: impl AsRef<Path>, 24 | | initial_capacity: usize, 25 | | ) -> color_eyre::Result<Self> { | |_________________________________^ | = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#missing_safety_doc note: the lint level is defined here --> src/lib.rs:2:9 | 2 | #![warn(clippy::all, clippy::cargo)] | ^^^^^^^^^^^ = note: `#[warn(clippy::missing_safety_doc)]` implied by `#[warn(clippy::all)]`
function `as_bytes` is never used: src/util.rs#L24
warning: function `as_bytes` is never used --> src/util.rs:24:22 | 24 | pub(crate) unsafe fn as_bytes<T: ?Sized>(p: &T) -> &[u8] { | ^^^^^^^^ | = note: `#[warn(dead_code)]` on by default
unused variable: `other`: src/generic_storage/mmap_vec.rs#L182
warning: unused variable: `other` --> src/generic_storage/mmap_vec.rs:182:18 | 182 | fn eq(&self, other: &Self) -> bool { | ^^^^^ help: if this is intentional, prefix it with an underscore: `_other` | = note: `#[warn(unused_variables)]` on by default
unused imports: `MmapMut`, `MmapOptions`: src/cascading_merkle_tree.rs#L11
warning: unused imports: `MmapMut`, `MmapOptions` --> src/cascading_merkle_tree.rs:11:15 | 11 | use mmap_rs::{MmapMut, MmapOptions}; | ^^^^^^^ ^^^^^^^^^^^
unused imports: `fs::OpenOptions`, `io::Write`, `iter::repeat`, `path::PathBuf`: src/cascading_merkle_tree.rs#L2
warning: unused imports: `fs::OpenOptions`, `io::Write`, `iter::repeat`, `path::PathBuf` --> src/cascading_merkle_tree.rs:2:5 | 2 | fs::OpenOptions, | ^^^^^^^^^^^^^^^ 3 | io::Write, | ^^^^^^^^^ 4 | iter::repeat, | ^^^^^^^^^^^^ 5 | ops::{Deref, DerefMut}, 6 | path::PathBuf, | ^^^^^^^^^^^^^ | = note: `#[warn(unused_imports)]` on by default
Lint
Node.js 16 actions are deprecated. Please update the following actions to use Node.js 20: actions/checkout@v3, actions-rs/toolchain@v1, actions-rs/cargo@v1, actions-rs/clippy-check@v1. For more information see: https://github.blog/changelog/2023-09-22-github-actions-transitioning-from-node-16-to-node-20/.
Lint
The following actions uses node12 which is deprecated and will be forced to run on node16: actions-rs/toolchain@v1, actions-rs/cargo@v1, actions-rs/clippy-check@v1. For more info: https://github.blog/changelog/2023-06-13-github-actions-all-actions-will-run-on-node16-instead-of-node12-by-default/
Lint
The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
Lint
The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
Lint
The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
Lint
The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
Test
Node.js 16 actions are deprecated. Please update the following actions to use Node.js 20: actions/checkout@v3, actions-rs/toolchain@v1, actions-rs/cargo@v1. For more information see: https://github.blog/changelog/2023-09-22-github-actions-transitioning-from-node-16-to-node-20/.
Test
The following actions uses node12 which is deprecated and will be forced to run on node16: actions-rs/toolchain@v1, actions-rs/cargo@v1. For more info: https://github.blog/changelog/2023-06-13-github-actions-all-actions-will-run-on-node16-instead-of-node12-by-default/
Test
The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
Test
The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
Test
The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
Test
The `set-output` command is deprecated and will be disabled soon. Please upgrade to using Environment Files. For more information see: https://github.blog/changelog/2022-10-11-github-actions-deprecating-save-state-and-set-output-commands/
Test: src/cascading_merkle_tree.rs#L2
unused imports: `fs::OpenOptions`, `io::Write`, `iter::repeat`, `path::PathBuf`
Test: src/cascading_merkle_tree.rs#L11
unused imports: `MmapMut`, `MmapOptions`
Test: src/generic_storage/mmap_vec.rs#L182
unused variable: `other`
Test: src/util.rs#L24
function `as_bytes` is never used
Test
`semaphore` (lib) generated 4 warnings (run `cargo fix --lib -p semaphore` to apply 3 suggestions)