reviewdog [clippy] report
reported by reviewdog 🐶
Findings (2)
programs/protocol-contracts-solana/src/lib.rs|165 col 10| error[E0308]: mismatched types
--> programs/protocol-contracts-solana/src/lib.rs:165:10
|
160 | pub fn deposit_spl_token_and_call(
| -------------------------- implicitly returns ()
as its body has no tail or return
expression
...
165 | ) -> Result<()> {
| ^^^^^^^^^^ expected Result<(), Error>
, found ()
...
168 | Ok(());
| - help: remove this semicolon to return this value
|
= note: expected enum std::result::Result<(), anchor_lang::error::Error>
found unit type ()
programs/protocol-contracts-solana/src/lib.rs|127 col 9| warning: unused variable: receiver
--> programs/protocol-contracts-solana/src/lib.rs:127:9
|
127 | receiver: [u8; 20], // unused in this program; for directing zetachain protocol only
| ^^^^^^^^ help: if this is intentional, prefix it with an underscore: _receiver
|
= note: #[warn(unused_variables)]
on by default
Filtered Findings (0)
Annotations
Check failure on line 165 in programs/protocol-contracts-solana/src/lib.rs
github-actions / clippy
[clippy] programs/protocol-contracts-solana/src/lib.rs#L165
error[E0308]: mismatched types
--> programs/protocol-contracts-solana/src/lib.rs:165:10
|
160 | pub fn deposit_spl_token_and_call(
| -------------------------- implicitly returns `()` as its body has no tail or `return` expression
...
165 | ) -> Result<()> {
| ^^^^^^^^^^ expected `Result<(), Error>`, found `()`
...
168 | Ok(());
| - help: remove this semicolon to return this value
|
= note: expected enum `std::result::Result<(), anchor_lang::error::Error>`
found unit type `()`
Raw output
programs/protocol-contracts-solana/src/lib.rs:165:10:e:error[E0308]: mismatched types
--> programs/protocol-contracts-solana/src/lib.rs:165:10
|
160 | pub fn deposit_spl_token_and_call(
| -------------------------- implicitly returns `()` as its body has no tail or `return` expression
...
165 | ) -> Result<()> {
| ^^^^^^^^^^ expected `Result<(), Error>`, found `()`
...
168 | Ok(());
| - help: remove this semicolon to return this value
|
= note: expected enum `std::result::Result<(), anchor_lang::error::Error>`
found unit type `()`
__END__
Check warning on line 127 in programs/protocol-contracts-solana/src/lib.rs
github-actions / clippy
[clippy] programs/protocol-contracts-solana/src/lib.rs#L127
warning: unused variable: `receiver`
--> programs/protocol-contracts-solana/src/lib.rs:127:9
|
127 | receiver: [u8; 20], // unused in this program; for directing zetachain protocol only
| ^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_receiver`
|
= note: `#[warn(unused_variables)]` on by default
Raw output
programs/protocol-contracts-solana/src/lib.rs:127:9:w:warning: unused variable: `receiver`
--> programs/protocol-contracts-solana/src/lib.rs:127:9
|
127 | receiver: [u8; 20], // unused in this program; for directing zetachain protocol only
| ^^^^^^^^ help: if this is intentional, prefix it with an underscore: `_receiver`
|
= note: `#[warn(unused_variables)]` on by default
__END__