docs: add a few clarifying docs (#2310)

This commit is contained in:
Matthias Seitz
2023-04-20 09:24:09 +02:00
committed by GitHub
parent 3b0dd3fb35
commit 64e3a57dd9
2 changed files with 3 additions and 2 deletions

View File

@@ -16,7 +16,8 @@ use std::collections::BTreeMap;
/// Used inside the BlockchainTree.
#[derive(Clone, Debug, Default, PartialEq, Eq)]
pub struct Chain {
/// The state of accounts after execution of the blocks in this chain (tip of the chain).
/// The state of all accounts after execution of the _all_ blocks in this chain's range from
/// [Chain::first] to [Chain::tip], inclusive.
///
/// This state also contains the individual changes that lead to the current state.
pub state: PostState,

View File

@@ -217,7 +217,7 @@ impl PostState {
}
}
/// Get the latest state of accounts.
/// Get the latest state of all changed accounts.
pub fn accounts(&self) -> &BTreeMap<Address, Option<Account>> {
&self.accounts
}