feat: pallet assets pop api integration #109
clippy
12 warnings
Details
Results
Message level | Amount |
---|---|
Internal compiler error | 0 |
Error | 0 |
Warning | 12 |
Note | 0 |
Help | 0 |
Versions
- rustc 1.79.0 (129f3b996 2024-06-10)
- cargo 1.79.0 (ffa9cf99a 2024-06-03)
- clippy 0.1.79 (129f3b9 2024-06-10)
Annotations
Check warning on line 54 in scripts/fund-dev-accounts/./main.rs
github-actions / clippy
used a field initializer for a tuple struct
warning: used a field initializer for a tuple struct
--> scripts/fund-dev-accounts/./main.rs:54:9
|
54 | id: AssetId { 0: Location { parents: 0, interior: Junctions::Here } },
| ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `AssetId(Location { parents: 0, interior: Junctions::Here })`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#init_numbered_fields
Check warning on line 57 in scripts/fund-dev-accounts/./main.rs
github-actions / clippy
used a field initializer for a tuple struct
warning: used a field initializer for a tuple struct
--> scripts/fund-dev-accounts/./main.rs:52:36
|
52 | let assets = VersionedAssets::V4(Assets {
| __________________________________________^
53 | | 0: vec![Asset {
54 | | id: AssetId { 0: Location { parents: 0, interior: Junctions::Here } },
55 | | fun: amount,
56 | | }],
57 | | });
| |_________^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#init_numbered_fields
= note: `#[warn(clippy::init_numbered_fields)]` on by default
help: try
|
52 ~ let assets = VersionedAssets::V4(Assets(<[_]>::into_vec(
53 + // This rustc_box is not required, but it produces a dramatic improvement in compile
54 + // time when constructing arrays with many elements.
55 + #[rustc_box]
56 + $crate::boxed::Box::new([$($x),+])
57 ~ )));
|
Check warning on line 49 in node/src/cli.rs
github-actions / clippy
large size difference between variants
warning: large size difference between variants
--> node/src/cli.rs:5:1
|
5 | / pub enum Subcommand {
6 | | /// Build a chain specification.
7 | | BuildSpec(sc_cli::BuildSpecCmd),
... |
19 | | ImportBlocks(sc_cli::ImportBlocksCmd),
| | ------------------------------------- the second-largest variant contains at least 240 bytes
... |
39 | | Benchmark(frame_benchmarking_cli::BenchmarkCmd),
| | ----------------------------------------------- the largest variant contains at least 512 bytes
... |
48 | | Key(sc_cli::KeySubcommand),
49 | | }
| |_^ the entire enum is at least 512 bytes
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#large_enum_variant
= note: `#[warn(clippy::large_enum_variant)]` on by default
help: consider boxing the large fields to reduce the total size of the enum
|
39 | Benchmark(Box<frame_benchmarking_cli::BenchmarkCmd>),
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Check warning on line 377 in runtime/testnet/src/lib.rs
github-actions / clippy
use of deprecated struct `pallet_transaction_payment::CurrencyAdapter`: Please use the fungible trait and FungibleAdapter. This struct will be removed some time after March 2024.
warning: use of deprecated struct `pallet_transaction_payment::CurrencyAdapter`: Please use the fungible trait and FungibleAdapter. This struct will be removed some time after March 2024.
--> runtime/testnet/src/lib.rs:377:57
|
377 | type OnChargeTransaction = pallet_transaction_payment::CurrencyAdapter<Balances, ()>;
| ^^^^^^^^^^^^^^^
|
= note: `#[warn(deprecated)]` on by default
Check warning on line 44 in runtime/testnet/src/extensions.rs
github-actions / clippy
bound is defined in more than one place
warning: bound is defined in more than one place
--> runtime/testnet/src/extensions.rs:44:10
|
44 | fn call<E: Ext>(&mut self, env: Environment<E, InitState>) -> Result<RetVal, DispatchError>
| ^
45 | where
46 | E: Ext<T = T>,
| ^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#multiple_bound_locations
= note: `#[warn(clippy::multiple_bound_locations)]` on by default
Check warning on line 409 in runtime/devnet/src/lib.rs
github-actions / clippy
use of deprecated struct `pallet_transaction_payment::CurrencyAdapter`: Please use the fungible trait and FungibleAdapter. This struct will be removed some time after March 2024.
warning: use of deprecated struct `pallet_transaction_payment::CurrencyAdapter`: Please use the fungible trait and FungibleAdapter. This struct will be removed some time after March 2024.
--> runtime/devnet/src/lib.rs:409:57
|
409 | type OnChargeTransaction = pallet_transaction_payment::CurrencyAdapter<Balances, ()>;
| ^^^^^^^^^^^^^^^
|
= note: `#[warn(deprecated)]` on by default
Check warning on line 66 in runtime/devnet/src/extensions/mod.rs
github-actions / clippy
bound is defined in more than one place
warning: bound is defined in more than one place
--> runtime/devnet/src/extensions/mod.rs:66:10
|
66 | fn call<E: Ext>(&mut self, env: Environment<E, InitState>) -> Result<RetVal, DispatchError>
| ^
67 | where
68 | E: Ext<T = T>,
| ^
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#multiple_bound_locations
= note: `#[warn(clippy::multiple_bound_locations)]` on by default
Check warning on line 70 in primitives/src/lib.rs
github-actions / clippy
casting integer literal to `u8` is unnecessary
warning: casting integer literal to `u8` is unnecessary
--> primitives/src/lib.rs:68:4
|
68 | / /// The number of transactional layers has been reached, or we are not in a transactional
69 | | /// layer.
70 | | Transactional(TransactionalError) = 9,
| |_________________________________________________^ help: try: `9_u8`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast
Check warning on line 67 in primitives/src/lib.rs
github-actions / clippy
casting integer literal to `u8` is unnecessary
warning: casting integer literal to `u8` is unnecessary
--> primitives/src/lib.rs:66:4
|
66 | / /// An arithmetic error.
67 | | Arithmetic(ArithmeticError) = 8,
| |___________________________________________^ help: try: `8_u8`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast
Check warning on line 65 in primitives/src/lib.rs
github-actions / clippy
casting integer literal to `u8` is unnecessary
warning: casting integer literal to `u8` is unnecessary
--> primitives/src/lib.rs:64:4
|
64 | / /// An error to do with tokens.
65 | | Token(TokenError) = 7,
| |_________________________________^ help: try: `7_u8`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast
Check warning on line 57 in primitives/src/lib.rs
github-actions / clippy
casting integer literal to `u8` is unnecessary
warning: casting integer literal to `u8` is unnecessary
--> primitives/src/lib.rs:56:4
|
56 | / /// A custom error in a module.
57 | | Module { index: u8, error: u8 } = 3,
| |_______________________________________________^ help: try: `3_u8`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast
Check warning on line 51 in primitives/src/lib.rs
github-actions / clippy
casting integer literal to `u8` is unnecessary
warning: casting integer literal to `u8` is unnecessary
--> primitives/src/lib.rs:43:4
|
43 | / /// Some unknown error occurred. Go to the Pop API docs section `Pop API error`.
44 | | Other {
45 | | // Index within the `DispatchError`
46 | | dispatch_error_index: u8,
... |
50 | | error: u8,
51 | | } = 0,
| |_________________^ help: try: `0_u8`
|
= help: for further information visit https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast
= note: `#[warn(clippy::unnecessary_cast)]` on by default