From 82288d4457421808a4fd7df1e7cc17897077225b Mon Sep 17 00:00:00 2001 From: Illia Bobyr Date: Mon, 6 Mar 2023 12:30:50 -0800 Subject: [PATCH] accounts_db::get_all_accounts: Select slots with an iterator (#30581) As `Range` is a special case of an `Iterator`, this is a generalization that makes `get_all_accounts()` accept other kinds of ranges. Such as `RangeInclusive`. --- runtime/src/accounts_db.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/runtime/src/accounts_db.rs b/runtime/src/accounts_db.rs index f119470ba8..9c1805609c 100644 --- a/runtime/src/accounts_db.rs +++ b/runtime/src/accounts_db.rs @@ -17362,7 +17362,7 @@ pub mod tests { pub(crate) fn get_all_accounts( db: &AccountsDb, - slots: Range, + slots: impl Iterator, ) -> Vec<(Pubkey, AccountSharedData)> { slots .filter_map(|slot| {