Skip to content

Commit

Permalink
Cleans up the feature gate of enable_early_verification_of_account_mo…
Browse files Browse the repository at this point in the history
…difications:

- Removes PreAccount
- Removes InvokeContext::pre_accounts and InvokeContext::rent
- Removes InvokeContext::verify() and InvokeContext::verify_and_update()
- Removes TransactionContext::is_early_verification_of_account_modifications_enabled()
- Removes TransactionAccounts::is_early_verification_of_account_modifications_enabled
- No longer optional: TransactionContext::rent
  • Loading branch information
Lichtso committed Oct 9, 2023
1 parent 7afb11f commit ff44e4d
Show file tree
Hide file tree
Showing 13 changed files with 112 additions and 1,183 deletions.
7 changes: 5 additions & 2 deletions accounts-db/src/transaction_results.rs
Original file line number Diff line number Diff line change
Expand Up @@ -176,13 +176,16 @@ pub fn inner_instructions_list_from_instruction_trace(

#[cfg(test)]
mod tests {
use {super::*, solana_sdk::transaction_context::TransactionContext};
use {
super::*,
solana_sdk::{sysvar::rent::Rent, transaction_context::TransactionContext},
};

#[test]
fn test_inner_instructions_list_from_instruction_trace() {
let instruction_trace = [1, 2, 1, 1, 2, 3, 2];
let mut transaction_context =
TransactionContext::new(vec![], None, 3, instruction_trace.len());
TransactionContext::new(vec![], Rent::default(), 3, instruction_trace.len());
for (index_in_trace, stack_height) in instruction_trace.into_iter().enumerate() {
while stack_height <= transaction_context.get_instruction_context_stack_height() {
transaction_context.pop().unwrap();
Expand Down
101 changes: 0 additions & 101 deletions program-runtime/benches/pre_account.rs

This file was deleted.

Loading

0 comments on commit ff44e4d

Please sign in to comment.