From 884c23afb8797971a7d66d98651e66a3b40f2906 Mon Sep 17 00:00:00 2001 From: Martin Holst Swende Date: Thu, 25 Apr 2024 08:15:23 +0200 Subject: [PATCH] core/state: lint nits --- core/state/access_list.go | 4 ++-- core/state/statedb_test.go | 1 - 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/core/state/access_list.go b/core/state/access_list.go index 89815b0fa1..b0effbeadc 100644 --- a/core/state/access_list.go +++ b/core/state/access_list.go @@ -149,7 +149,7 @@ func (al *accessList) Equal(other *accessList) bool { func (al *accessList) PrettyPrint() string { out := new(strings.Builder) var sortedAddrs []common.Address - for addr, _ := range al.addresses { + for addr := range al.addresses { sortedAddrs = append(sortedAddrs, addr) } slices.SortFunc(sortedAddrs, common.Address.Cmp) @@ -158,7 +158,7 @@ func (al *accessList) PrettyPrint() string { fmt.Fprintf(out, "%#x : (idx %d)\n", addr, idx) if idx >= 0 { slotmap := al.slots[idx] - for h, _ := range slotmap { + for h := range slotmap { fmt.Fprintf(out, " %#x\n", h) } } diff --git a/core/state/statedb_test.go b/core/state/statedb_test.go index 8ae443e7c5..71d64f5628 100644 --- a/core/state/statedb_test.go +++ b/core/state/statedb_test.go @@ -637,7 +637,6 @@ func (test *snapshotTest) checkEqual(state, checkstate *StateDB) error { print(obj.dirtyStorage), print(other.dirtyStorage)) } - } // Check transient storage. {