Skip to content

Commit

Permalink
Remove extra ;
Browse files Browse the repository at this point in the history
  • Loading branch information
teor2345 authored Nov 21, 2023
1 parent dbd41b7 commit 78b3b64
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ impl ZebraDb {
// In Zebra 1.4.0 and later, we don't update the sprout tip tree unless it is changed.

Check failure on line 112 in zebra-state/src/service/finalized_state/zebra_db/shielded.rs

View workflow job for this annotation

GitHub Actions / Rustfmt

Diff in /home/runner/work/zebra/zebra/zebra-state/src/service/finalized_state/zebra_db/shielded.rs
// And we write with a `()` key, not a height key.
// So we need to look for the most recent update height if the `()` key has never been written.
sprout_tree = self.db.zs_last_key_value(&sprout_tree_cf).map(|(_height_key, tree_value)| tree_value);;
sprout_tree = self.db.zs_last_key_value(&sprout_tree_cf).map(|(_height_key, tree_value)| tree_value);

Check failure on line 115 in zebra-state/src/service/finalized_state/zebra_db/shielded.rs

View workflow job for this annotation

GitHub Actions / Build and Deploy Zebra Internal Docs

type annotations needed for `(K, Arc<zebra_chain::sprout::tree::NoteCommitmentTree>)`

Check failure on line 115 in zebra-state/src/service/finalized_state/zebra_db/shielded.rs

View workflow job for this annotation

GitHub Actions / Check Cargo.lock is up to date

type annotations needed for `(K, Arc<zebra_chain::sprout::tree::NoteCommitmentTree>)`

Check failure on line 115 in zebra-state/src/service/finalized_state/zebra_db/shielded.rs

View workflow job for this annotation

GitHub Actions / Test stable on ubuntu-latest

type annotations needed for `(K, Arc<zebra_chain::sprout::tree::NoteCommitmentTree>)`

Check failure on line 115 in zebra-state/src/service/finalized_state/zebra_db/shielded.rs

View workflow job for this annotation

GitHub Actions / Test beta on ubuntu-latest

type annotations needed for `(K, Arc<zebra_chain::sprout::tree::NoteCommitmentTree>)`

Check failure on line 115 in zebra-state/src/service/finalized_state/zebra_db/shielded.rs

View workflow job for this annotation

GitHub Actions / Test stable on macos-latest

type annotations needed for `(K, Arc<zebra_chain::sprout::tree::NoteCommitmentTree>)`

Check failure on line 115 in zebra-state/src/service/finalized_state/zebra_db/shielded.rs

View workflow job for this annotation

GitHub Actions / Clippy (stable) Results

type annotations needed for `(K, std::sync::Arc<zebra_chain::sprout::tree::NoteCommitmentTree>)`

error[E0283]: type annotations needed for `(K, std::sync::Arc<zebra_chain::sprout::tree::NoteCommitmentTree>)` --> zebra-state/src/service/finalized_state/zebra_db/shielded.rs:115:75 | 115 | sprout_tree = self.db.zs_last_key_value(&sprout_tree_cf).map(|(_height_key, tree_value)| tree_value); | ----------------- ^^^^^^^^^^^^^^^^^^^^^^^^^ | | | type must be known at this point | = note: cannot satisfy `_: service::finalized_state::disk_format::IntoDisk` = help: the following types implement trait `service::finalized_state::disk_format::IntoDisk`: service::finalized_state::disk_format::block::TransactionIndex service::finalized_state::disk_format::block::TransactionLocation service::finalized_state::disk_format::transparent::OutputIndex service::finalized_state::disk_format::transparent::OutputLocation service::finalized_state::disk_format::transparent::AddressBalanceLocation service::finalized_state::disk_format::transparent::AddressUnspentOutput service::finalized_state::disk_format::transparent::AddressTransaction zebra_chain::amount::Amount<zebra_chain::amount::NonNegative> and 26 others note: required by a bound in `service::finalized_state::disk_db::ReadDisk::zs_last_key_value` --> zebra-state/src/service/finalized_state/disk_db.rs:207:12 | 204 | fn zs_last_key_value<C, K, V>(&self, cf: &C) -> Option<(K, V)> | ----------------- required by a bound in this associated function ... 207 | K: IntoDisk + FromDisk, | ^^^^^^^^ required by this bound in `ReadDisk::zs_last_key_value` help: consider giving this closure parameter an explicit type, where the type for type parameter `K` is specified | 115 | sprout_tree = self.db.zs_last_key_value(&sprout_tree_cf).map(|(_height_key, tree_value): (K, std::sync::Arc<zebra_chain::sprout::tree::NoteCommitmentTree>)| tree_value); | ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Check failure on line 115 in zebra-state/src/service/finalized_state/zebra_db/shielded.rs

View workflow job for this annotation

GitHub Actions / Clippy (stable) Results

type annotations needed for `(K, std::sync::Arc<zebra_chain::sprout::tree::NoteCommitmentTree>)`

error[E0283]: type annotations needed for `(K, std::sync::Arc<zebra_chain::sprout::tree::NoteCommitmentTree>)` --> zebra-state/src/service/finalized_state/zebra_db/shielded.rs:115:75 | 115 | sprout_tree = self.db.zs_last_key_value(&sprout_tree_cf).map(|(_height_key, tree_value)| tree_value); | ----------------- ^^^^^^^^^^^^^^^^^^^^^^^^^ | | | type must be known at this point | = note: cannot satisfy `_: service::finalized_state::disk_format::IntoDisk` = help: the following types implement trait `service::finalized_state::disk_format::IntoDisk`: service::finalized_state::disk_format::block::TransactionIndex service::finalized_state::disk_format::block::TransactionLocation service::finalized_state::disk_format::transparent::OutputIndex service::finalized_state::disk_format::transparent::OutputLocation service::finalized_state::disk_format::transparent::AddressBalanceLocation service::finalized_state::disk_format::transparent::AddressUnspentOutput service::finalized_state::disk_format::transparent::AddressTransaction zebra_chain::amount::Amount<zebra_chain::amount::NonNegative> and 26 others note: required by a bound in `service::finalized_state::disk_db::ReadDisk::zs_last_key_value` --> zebra-state/src/service/finalized_state/disk_db.rs:207:12 | 204 | fn zs_last_key_value<C, K, V>(&self, cf: &C) -> Option<(K, V)> | ----------------- required by a bound in this associated function ... 207 | K: IntoDisk + FromDisk, | ^^^^^^^^ required by this bound in `ReadDisk::zs_last_key_value` help: consider giving this closure parameter an explicit type, where the type for type parameter `K` is specified | 115 | sprout_tree = self.db.zs_last_key_value(&sprout_tree_cf).map(|(_height_key, tree_value): (K, std::sync::Arc<zebra_chain::sprout::tree::NoteCommitmentTree>)| tree_value); | ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
}

sprout_tree.expect("Sprout note commitment tree must exist if there is a finalized tip")
Expand Down

0 comments on commit 78b3b64

Please sign in to comment.