From c29cf44c76e27276011af18789dd70e65621b047 Mon Sep 17 00:00:00 2001 From: Michael Sproul Date: Thu, 8 Dec 2022 16:24:15 +1100 Subject: [PATCH] Document historical_batch calculation --- consensus/types/src/beacon_state.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/consensus/types/src/beacon_state.rs b/consensus/types/src/beacon_state.rs index 0583ce83f3..467224ba48 100644 --- a/consensus/types/src/beacon_state.rs +++ b/consensus/types/src/beacon_state.rs @@ -473,7 +473,7 @@ impl BeaconState { } pub fn historical_batch(&mut self) -> Result, Error> { - // FIXME(sproul): work out how to clean this up (internal mutability?) + // Updating before cloning makes the clone cheap and saves repeated hashing. self.block_roots_mut().apply_updates()?; self.state_roots_mut().apply_updates()?;