Skip to content
GitHub Actions / clippy failed Nov 20, 2023 in 0s

clippy

4 errors

Details

Results

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

Versions

  • rustc 1.76.0-nightly (9a66e4471 2023-11-19)
  • cargo 1.76.0-nightly (9765a449d 2023-11-17)
  • clippy 0.1.76 (9a66e44 2023-11-19)

Annotations

Check failure on line 327 in solana/solana-ibc/programs/solana-ibc/src/validation_context.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

error: this expression creates a reference which is immediately dereferenced by the compiler
   --> solana/solana-ibc/programs/solana-ibc/src/validation_context.rs:327:22
    |
327 |                 .get(&port_channel)
    |                      ^^^^^^^^^^^^^ help: change this to: `port_channel`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#needless_borrow
    = note: `-D clippy::needless-borrow` implied by `-D warnings`
    = help: to override `-D warnings` add `#[allow(clippy::needless_borrow)]`

Check failure on line 238 in solana/solana-ibc/programs/solana-ibc/src/storage/trie_key.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

useless conversion to the same type: `u32`

error: useless conversion to the same type: `u32`
   --> solana/solana-ibc/programs/solana-ibc/src/storage/trie_key.rs:238:9
    |
238 |         u32::from(self.channel_idx).append_into(dest);
    |         ^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider removing `u32::from()`: `self.channel_idx`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion

Check failure on line 232 in solana/solana-ibc/programs/solana-ibc/src/storage/trie_key.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

useless conversion to the same type: `u32`

error: useless conversion to the same type: `u32`
   --> solana/solana-ibc/programs/solana-ibc/src/storage/trie_key.rs:232:27
    |
232 |         1 + port_id_len + u32::from(self.channel_idx).key_len()
    |                           ^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: consider removing `u32::from()`: `self.channel_idx`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#useless_conversion
    = note: `-D clippy::useless-conversion` implied by `-D warnings`
    = help: to override `-D warnings` add `#[allow(clippy::useless_conversion)]`

Check failure on line 163 in solana/solana-ibc/programs/solana-ibc/src/storage/ids.rs

See this annotation in the file changed.

@github-actions github-actions / clippy

deref which would be done by auto-deref

error: deref which would be done by auto-deref
   --> solana/solana-ibc/programs/solana-ibc/src/storage/ids.rs:163:30
    |
163 |     fn as_ref(&self) -> &T { *self }
    |                              ^^^^^ help: try: `self`
    |
    = help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#explicit_auto_deref
    = note: `-D clippy::explicit-auto-deref` implied by `-D warnings`
    = help: to override `-D warnings` add `#[allow(clippy::explicit_auto_deref)]`