diff --git a/contracts/coconut-bandwidth/src/storage.rs b/contracts/coconut-bandwidth/src/storage.rs index f18bc6fa28..aa671bbbcb 100644 --- a/contracts/coconut-bandwidth/src/storage.rs +++ b/contracts/coconut-bandwidth/src/storage.rs @@ -18,7 +18,7 @@ pub(crate) struct SpendCredentialIndex<'a> { // IndexList is just boilerplate code for fetching a struct's indexes // note that from my understanding this will be converted into a macro at some point in the future -impl<'a> IndexList for SpendCredentialIndex<'a> { +impl IndexList for SpendCredentialIndex<'_> { fn get_indexes(&'_ self) -> Box> + '_> { let v: Vec<&dyn Index> = vec![&self.blinded_serial_number]; Box::new(v.into_iter()) diff --git a/contracts/mixnet/src/delegations/storage.rs b/contracts/mixnet/src/delegations/storage.rs index 3fa2931f64..25cd6844c9 100644 --- a/contracts/mixnet/src/delegations/storage.rs +++ b/contracts/mixnet/src/delegations/storage.rs @@ -17,7 +17,7 @@ pub(crate) struct DelegationIndex<'a> { pub(crate) mixnode: MultiIndex<'a, NodeId, Delegation, PrimaryKey>, } -impl<'a> IndexList for DelegationIndex<'a> { +impl IndexList for DelegationIndex<'_> { fn get_indexes(&'_ self) -> Box> + '_> { let v: Vec<&dyn Index> = vec![&self.owner, &self.mixnode]; Box::new(v.into_iter()) diff --git a/contracts/mixnet/src/gateways/storage.rs b/contracts/mixnet/src/gateways/storage.rs index 95bf11dcc9..9a530fec8d 100644 --- a/contracts/mixnet/src/gateways/storage.rs +++ b/contracts/mixnet/src/gateways/storage.rs @@ -18,7 +18,7 @@ pub(crate) struct GatewayBondIndex<'a> { // IndexList is just boilerplate code for fetching a struct's indexes // note that from my understanding this will be converted into a macro at some point in the future -impl<'a> IndexList for GatewayBondIndex<'a> { +impl IndexList for GatewayBondIndex<'_> { fn get_indexes(&'_ self) -> Box> + '_> { let v: Vec<&dyn Index> = vec![&self.owner]; Box::new(v.into_iter()) diff --git a/contracts/mixnet/src/mixnodes/storage.rs b/contracts/mixnet/src/mixnodes/storage.rs index 1a68bbebfb..8344926b7e 100644 --- a/contracts/mixnet/src/mixnodes/storage.rs +++ b/contracts/mixnet/src/mixnodes/storage.rs @@ -24,7 +24,7 @@ pub(crate) struct UnbondedMixnodeIndex<'a> { pub(crate) identity_key: MultiIndex<'a, IdentityKey, UnbondedMixnode, NodeId>, } -impl<'a> IndexList for UnbondedMixnodeIndex<'a> { +impl IndexList for UnbondedMixnodeIndex<'_> { fn get_indexes(&'_ self) -> Box> + '_> { let v: Vec<&dyn Index> = vec![&self.owner, &self.identity_key]; Box::new(v.into_iter()) @@ -58,7 +58,7 @@ pub(crate) struct MixnodeBondIndex<'a> { // IndexList is just boilerplate code for fetching a struct's indexes // note that from my understanding this will be converted into a macro at some point in the future -impl<'a> IndexList for MixnodeBondIndex<'a> { +impl IndexList for MixnodeBondIndex<'_> { fn get_indexes(&'_ self) -> Box> + '_> { let v: Vec<&dyn Index> = vec![&self.owner, &self.identity_key, &self.sphinx_key]; diff --git a/contracts/mixnet/src/nodes/storage/mod.rs b/contracts/mixnet/src/nodes/storage/mod.rs index c431e4af08..63584010a6 100644 --- a/contracts/mixnet/src/nodes/storage/mod.rs +++ b/contracts/mixnet/src/nodes/storage/mod.rs @@ -75,7 +75,7 @@ pub(crate) struct NymNodeBondIndex<'a> { pub(crate) identity_key: UniqueIndex<'a, IdentityKey, NymNodeBond>, } -impl<'a> IndexList for NymNodeBondIndex<'a> { +impl IndexList for NymNodeBondIndex<'_> { fn get_indexes(&'_ self) -> Box> + '_> { let v: Vec<&dyn Index> = vec![&self.owner, &self.identity_key]; Box::new(v.into_iter()) @@ -103,7 +103,7 @@ pub(crate) struct UnbondedNymNodeIndex<'a> { pub(crate) identity_key: MultiIndex<'a, IdentityKey, UnbondedNymNode, NodeId>, } -impl<'a> IndexList for UnbondedNymNodeIndex<'a> { +impl IndexList for UnbondedNymNodeIndex<'_> { fn get_indexes(&'_ self) -> Box> + '_> { let v: Vec<&dyn Index> = vec![&self.owner, &self.identity_key]; Box::new(v.into_iter()) diff --git a/contracts/mixnet/src/queued_migrations.rs b/contracts/mixnet/src/queued_migrations.rs index 9521172bcb..15cb9a6d43 100644 --- a/contracts/mixnet/src/queued_migrations.rs +++ b/contracts/mixnet/src/queued_migrations.rs @@ -52,7 +52,7 @@ mod families_purge { pub label: UniqueIndex<'a, FamilyHeadKey, Family>, } - impl<'a> IndexList for FamilyIndex<'a> { + impl IndexList for FamilyIndex<'_> { fn get_indexes(&'_ self) -> Box> + '_> { let v: Vec<&dyn Index> = vec![&self.label]; Box::new(v.into_iter()) diff --git a/contracts/vesting/src/vesting/account/vesting_account.rs b/contracts/vesting/src/vesting/account/vesting_account.rs index 6406df460d..3c2beb142e 100644 --- a/contracts/vesting/src/vesting/account/vesting_account.rs +++ b/contracts/vesting/src/vesting/account/vesting_account.rs @@ -14,7 +14,6 @@ impl VestingAccount for Account { /// See [VestingAccount::locked_coins] for documentation. /// Returns 0 in case of underflow. Which is fine, as the amount of pledged and delegated tokens can be larger then vesting_coins due to rewards and vesting periods expiring - // TODO: rename. it's no longer 'locked'... or is it? fn locked_coins( &self,