Skip to content

Commit 3e8d4e4

Browse files
committed
core/types: create libevm.go containing extras registration moved from state_account.go
1 parent c8f62fa commit 3e8d4e4

File tree

2 files changed

+15
-8
lines changed

2 files changed

+15
-8
lines changed

core/types/libevm.go

Lines changed: 14 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,14 @@
1+
// (c) 2025, Ava Labs, Inc. All rights reserved.
2+
// See the file LICENSE for licensing terms.
3+
4+
package types
5+
6+
import (
7+
ethtypes "github.com/ava-labs/libevm/core/types"
8+
)
9+
10+
var extras = ethtypes.RegisterExtras[
11+
ethtypes.NOOPHeaderHooks, *ethtypes.NOOPHeaderHooks,
12+
ethtypes.NOOPBodyHooks, *ethtypes.NOOPBodyHooks,
13+
isMultiCoin,
14+
]()

core/types/state_account.go

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -32,14 +32,7 @@ import (
3232

3333
type isMultiCoin bool
3434

35-
var (
36-
extras = ethtypes.RegisterExtras[
37-
ethtypes.NOOPHeaderHooks, *ethtypes.NOOPHeaderHooks,
38-
ethtypes.NOOPBodyHooks, *ethtypes.NOOPBodyHooks,
39-
isMultiCoin,
40-
]()
41-
IsMultiCoinPayloads = extras.StateAccount
42-
)
35+
var IsMultiCoinPayloads = extras.StateAccount
4336

4437
func IsMultiCoin(s ethtypes.StateOrSlimAccount) bool {
4538
return bool(extras.StateAccount.Get(s))

0 commit comments

Comments
 (0)