Skip to content

perf: push FileSlices down through most of fast fields #6

perf: push FileSlices down through most of fast fields

perf: push FileSlices down through most of fast fields #6

GitHub Actions / clippy succeeded Jan 15, 2025 in 0s

clippy

9 warnings

Details

Results

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

Versions

  • rustc 1.84.0 (9fc6b4312 2025-01-07)
  • cargo 1.84.0 (66221abde 2024-11-19)
  • clippy 0.1.84 (9fc6b43126 2025-01-07)

Annotations

Check warning on line 295 in src/termdict/fst_termdict/streamer.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

method `next` can be confused for the standard trait method `std::iter::Iterator::next`

warning: method `next` can be confused for the standard trait method `std::iter::Iterator::next`
   --> src/termdict/fst_termdict/streamer.rs:288:5
    |
288 | /     pub fn next(&mut self) -> Option<(&[u8], &TermInfo, A::State)> {
289 | |         if self.advance() {
290 | |             let state = self.current_state.take().unwrap(); // always Some(_) after advance
291 | |             Some((self.key(), self.value(), state))
...   |
294 | |         }
295 | |     }
    | |_____^
    |
    = help: consider implementing the trait `std::iter::Iterator` or choosing a less ambiguous method name
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#should_implement_trait
    = note: `#[warn(clippy::should_implement_trait)]` on by default

Check warning on line 231 in src/termdict/fst_termdict/streamer.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

the following explicit lifetimes could be elided: 'a

warning: the following explicit lifetimes could be elided: 'a
   --> src/termdict/fst_termdict/streamer.rs:231:6
    |
231 | impl<'a, A> TermWithStateStreamer<'a, A>
    |      ^^                           ^^
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes
    = note: `#[warn(clippy::needless_lifetimes)]` on by default
help: elide the lifetimes
    |
231 - impl<'a, A> TermWithStateStreamer<'a, A>
231 + impl<A> TermWithStateStreamer<'_, A>
    |

Check warning on line 430 in src/indexer/segment_updater.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

this expression creates a reference which is immediately dereferenced by the compiler

warning: this expression creates a reference which is immediately dereferenced by the compiler
   --> src/indexer/segment_updater.rs:430:17
    |
430 |                 &previous_metas,
    |                 ^^^^^^^^^^^^^^^ help: change this to: `previous_metas`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow
    = note: `#[warn(clippy::needless_borrow)]` on by default

Check warning on line 295 in src/termdict/fst_termdict/streamer.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

method `next` can be confused for the standard trait method `std::iter::Iterator::next`

warning: method `next` can be confused for the standard trait method `std::iter::Iterator::next`
   --> src/termdict/fst_termdict/streamer.rs:288:5
    |
288 | /     pub fn next(&mut self) -> Option<(&[u8], &TermInfo, A::State)> {
289 | |         if self.advance() {
290 | |             let state = self.current_state.take().unwrap(); // always Some(_) after advance
291 | |             Some((self.key(), self.value(), state))
...   |
294 | |         }
295 | |     }
    | |_____^
    |
    = help: consider implementing the trait `std::iter::Iterator` or choosing a less ambiguous method name
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#should_implement_trait
    = note: `#[warn(clippy::should_implement_trait)]` on by default

Check warning on line 231 in src/termdict/fst_termdict/streamer.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

the following explicit lifetimes could be elided: 'a

warning: the following explicit lifetimes could be elided: 'a
   --> src/termdict/fst_termdict/streamer.rs:231:6
    |
231 | impl<'a, A> TermWithStateStreamer<'a, A>
    |      ^^                           ^^
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes
    = note: `#[warn(clippy::needless_lifetimes)]` on by default
help: elide the lifetimes
    |
231 - impl<'a, A> TermWithStateStreamer<'a, A>
231 + impl<A> TermWithStateStreamer<'_, A>
    |

Check warning on line 430 in src/indexer/segment_updater.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

this expression creates a reference which is immediately dereferenced by the compiler

warning: this expression creates a reference which is immediately dereferenced by the compiler
   --> src/indexer/segment_updater.rs:430:17
    |
430 |                 &previous_metas,
    |                 ^^^^^^^^^^^^^^^ help: change this to: `previous_metas`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow
    = note: `#[warn(clippy::needless_borrow)]` on by default

Check warning on line 201 in columnar/src/column_values/u64_based/mod.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

accessing first element with `header .read_bytes()? .as_slice().get(0)`

warning: accessing first element with `header
                 .read_bytes()?
                 .as_slice().get(0)`
   --> columnar/src/column_values/u64_based/mod.rs:198:33
    |
198 |       let codec_type: CodecType = header
    |  _________________________________^
199 | |         .read_bytes()?
200 | |         .as_slice()
201 | |         .get(0)
    | |_______________^
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#get_first
    = note: `#[warn(clippy::get_first)]` on by default
help: try
    |
198 ~     let codec_type: CodecType = header
199 +         .read_bytes()?
200 +         .as_slice().first()
    |

Check warning on line 396 in sstable/src/streamer.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

method `next` can be confused for the standard trait method `std::iter::Iterator::next`

warning: method `next` can be confused for the standard trait method `std::iter::Iterator::next`
   --> sstable/src/streamer.rs:389:5
    |
389 | /     pub fn next(&mut self) -> Option<(&[u8], &TSSTable::Value, A::State)> {
390 | |         if self.advance() {
391 | |             let st = self.current_state.clone().unwrap();
392 | |             Some((self.key(), self.value(), st))
...   |
395 | |         }
396 | |     }
    | |_____^
    |
    = help: consider implementing the trait `std::iter::Iterator` or choosing a less ambiguous method name
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#should_implement_trait
    = note: `#[warn(clippy::should_implement_trait)]` on by default

Check warning on line 362 in sstable/src/streamer.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

the following explicit lifetimes could be elided: 'a

warning: the following explicit lifetimes could be elided: 'a
   --> sstable/src/streamer.rs:362:6
    |
362 | impl<'a, TSSTable, A> StreamerWithState<'a, TSSTable, A>
    |      ^^                                 ^^
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_lifetimes
    = note: `#[warn(clippy::needless_lifetimes)]` on by default
help: elide the lifetimes
    |
362 - impl<'a, TSSTable, A> StreamerWithState<'a, TSSTable, A>
362 + impl<TSSTable, A> StreamerWithState<'_, TSSTable, A>
    |