Files
zeekayandHanzo Dev 86112af99e Go 1.27.1, and the code it can say more simply
Modules declare go 1.27.1 and the build images follow. go fix applied the
modernizers; omitzero is not applied, since it changes what the JSON says.

Co-authored-by: Hanzo Dev <[email protected]>
2026-09-16 19:15:44 -07:00

30 lines
766 B
Go

// Copyright (C) 2019-2025, Lux Industries Inc. All rights reserved.
// See the file LICENSE for licensing terms.
package vm
import (
"github.com/luxfi/ids"
"github.com/luxfi/log"
"github.com/luxfi/vm/vms"
)
var _ vms.Factory = (*Factory)(nil)
// VMID is the unique identifier for RelayVM (R-Chain)
var VMID = ids.ID{'r', 'e', 'l', 'a', 'y', 'v', 'm'}
// Factory creates new RelayVM instances
type Factory struct{}
// New returns a new instance of the RelayVM
func (f *Factory) New(logger log.Logger) (any, error) {
return &VM{
channels: make(map[ids.ID]*Channel),
messages: make(map[ids.ID]*Message),
pendingMsgs: make(map[ids.ID][]*Message),
sequences: make(map[ids.ID]uint64),
pendingBlocks: make(map[ids.ID]*Block),
}, nil
}