neoneo-go/pkg/config/hardfork_string.go
Anna Shaleva 5c75ee13d0 config, native: introduce Cockatrice hard-fork
With all associated native API changes ported from
https://github.com/neo-project/neo/pull/2925 and
https://github.com/neo-project/neo/pull/3154.

Signed-off-by: Anna Shaleva <shaleva.ann@nspcc.ru>
2024-04-25 13:26:54 +03:00

39 lines
864 B
Go

// Code generated by "stringer -type=Hardfork -linecomment"; DO NOT EDIT.
package config
import "strconv"
func _() {
// An "invalid array index" compiler error signifies that the constant values have changed.
// Re-run the stringer command to generate them again.
var x [1]struct{}
_ = x[HFDefault-0]
_ = x[HFAspidochelone-1]
_ = x[HFBasilisk-2]
_ = x[HFCockatrice-4]
_ = x[hfLast-8]
}
const (
_Hardfork_name_0 = "DefaultAspidocheloneBasilisk"
_Hardfork_name_1 = "Cockatrice"
_Hardfork_name_2 = "hfLast"
)
var (
_Hardfork_index_0 = [...]uint8{0, 7, 20, 28}
)
func (i Hardfork) String() string {
switch {
case i <= 2:
return _Hardfork_name_0[_Hardfork_index_0[i]:_Hardfork_index_0[i+1]]
case i == 4:
return _Hardfork_name_1
case i == 8:
return _Hardfork_name_2
default:
return "Hardfork(" + strconv.FormatInt(int64(i), 10) + ")"
}
}