docs: add docs about CachedReads (#15905)

Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
Co-authored-by: DaniPopes <57450786+DaniPopes@users.noreply.github.com>
This commit is contained in:
Matthias Seitz
2025-04-24 15:43:09 +02:00
committed by GitHub
parent 4d77608be1
commit bf59f5816c
2 changed files with 8 additions and 3 deletions

View File

@@ -11,6 +11,9 @@ use revm::{bytecode::Bytecode, state::AccountInfo, Database, DatabaseRef};
/// This is intended to be used in conjunction with `revm::db::State`
/// during payload building which repeatedly accesses the same data.
///
/// [`CachedReads::as_db_mut`] transforms this type into a [`Database`] implementation that uses
/// [`CachedReads`] as a caching layer for operations, and records any cache misses.
///
/// # Example
///
/// ```