Skip to content

Refactor + add clear #202

Refactor + add clear

Refactor + add clear #202

GitHub Actions / clippy succeeded Apr 9, 2024 in 0s

clippy

6 warnings

Details

Results

Message level Amount
Internal compiler error 0
Error 0
Warning 6
Note 0
Help 0

Versions

  • rustc 1.78.0-nightly (b11fbfbf3 2024-02-03)
  • cargo 1.78.0-nightly (7bb7b5395 2024-01-20)
  • clippy 0.1.77 (b11fbfb 2024-02-03)

Annotations

Check warning on line 62 in src/generic_storage/mmap_vec.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

unsafe function's docs miss `# Safety` section

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

Check warning on line 53 in src/generic_storage/mmap_vec.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

unsafe function's docs miss `# Safety` section

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

Check warning on line 40 in src/generic_storage/mmap_vec.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

unsafe function's docs miss `# Safety` section

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

Check warning on line 25 in src/generic_storage/mmap_vec.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

unsafe function's docs miss `# Safety` section

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)]`

Check warning on line 24 in src/util.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

function `as_bytes` is never used

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

Check warning on line 186 in src/generic_storage/mmap_vec.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

unused variable: `other`

warning: unused variable: `other`
   --> src/generic_storage/mmap_vec.rs:186:18
    |
186 |     fn eq(&self, other: &Self) -> bool {
    |                  ^^^^^ help: if this is intentional, prefix it with an underscore: `_other`
    |
    = note: `#[warn(unused_variables)]` on by default