solana
solana copied to clipboard
Remove unused AppendVecAccountsIter
Problem
AccountsFile already implements account_iter() where it constructs its own AccountsFileIter based on the get_account() API. As a result, AppendVec::account_iter() and AppendVecAccountsIter are unused.
Summary of Changes
Remove AppendVec::account_iter() and AppendVecAccountsIter.
Test Plan
Existing unit-tests.
Looks like the only place it is used is in the store-tool, but it can be replaced by the AccountsFile API:
error[E0599]: no method named `account_iter` found for struct `ManuallyDrop<solana_accounts_db::append_vec::AppendVec>` in the current scope
--
| --> accounts-db/store-tool/src/main.rs:48:26
| \|
| 48 \| for account in store.account_iter() {
| \| ^^^^^^^^^^^^ help: there is a method with a similar name: `accounts`