Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
ak88 committed Sep 26, 2024
1 parent 8d4ec6f commit 3ff576a
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 8 deletions.
4 changes: 0 additions & 4 deletions src/Nethermind/Nethermind.Evm/ICodeInfoRepository.cs
Original file line number Diff line number Diff line change
Expand Up @@ -17,10 +17,6 @@ public interface ICodeInfoRepository
CodeInfo GetCachedCodeInfo(IWorldState worldState, Address codeSource, IReleaseSpec vmSpec, out Address? delegationAddress);
ValueHash256 GetExecutableCodeHash(IWorldState worldState, Address address);
void InsertCode(IWorldState state, ReadOnlyMemory<byte> code, Address codeOwner, IReleaseSpec spec);

/// <summary>
/// Insert a delegation code into an <see cref="Account"/>.
/// </summary>
void SetDelegation(IWorldState state, Address codeSource, Address authority, IReleaseSpec spec);
bool TryGetDelegation(IReadOnlyStateProvider worldState, Address address, [NotNullWhen(true)] out Address? delegatedAddress);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -152,8 +152,8 @@ protected virtual TransactionResult Execute(Transaction tx, in BlockExecutionCon

if (commit) WorldState.Commit(spec, tracer.IsTracingState ? tracer : NullTxTracer.Instance, commitStorageRoots: false);

_warmAddressBuilder.StartNewBuild(spec);
int delegationRefunds = ProcessDelegations(tx, spec, _accessedAddresses);
JournalSet<Address> accessedAddresses = new();
int delegationRefunds = ProcessDelegations(tx, spec, accessedAddresses);

ExecutionEnvironment env = BuildExecutionEnvironment(tx, in blCtx, spec, effectiveGasPrice, _codeInfoRepository, _warmAddressBuilder);

Expand Down Expand Up @@ -207,7 +207,7 @@ protected virtual TransactionResult Execute(Transaction tx, in BlockExecutionCon
return TransactionResult.Ok;
}

private int ProcessDelegations(Transaction tx, IReleaseSpec spec, HashSet<Address> accessedAddresses)
private int ProcessDelegations(Transaction tx, IReleaseSpec spec, ICollection<Address> accessedAddresses)
{
int refunds = 0;
if (spec.IsEip7702Enabled && tx.HasAuthorizationList)
Expand Down Expand Up @@ -242,7 +242,7 @@ private int ProcessDelegations(Transaction tx, IReleaseSpec spec, HashSet<Addres

bool IsValidForExecution(
AuthorizationTuple authorizationTuple,
ISet<Address> accessedAddresses,
ICollection<Address> accessedAddresses,
[NotNullWhen(false)] out string? error)
{
if (authorizationTuple.Authority is null)
Expand Down

0 comments on commit 3ff576a

Please sign in to comment.