alphabet

package
v1.4.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Dec 22, 2023 License: MIT Imports: 10 Imported by: 0

Documentation

Index

Constants

View Source
const (
	L2ClaimBlockNumberLocalIndex = 4
)

Variables

View Source
var (
	ErrIndexTooLarge = errors.New("index is larger than the maximum index")
)

Functions

func BuildAlphabetPreimage

func BuildAlphabetPreimage(i *big.Int, letter string) []byte

BuildAlphabetPreimage constructs the claim bytes for the index and state item.

func LetterToBytes

func LetterToBytes(letter string) []byte

LetterToBytes converts a letter to a 32 byte array

Types

type AlphabetPrestateProvider added in v1.4.2

type AlphabetPrestateProvider struct{}

AlphabetPrestateProvider is a stateless [PrestateProvider] that uses a pre-determined, fixed pre-state hash.

func (*AlphabetPrestateProvider) AbsolutePreStateCommitment added in v1.4.2

func (ap *AlphabetPrestateProvider) AbsolutePreStateCommitment(_ context.Context) (common.Hash, error)

type AlphabetTraceProvider

type AlphabetTraceProvider struct {
	AlphabetPrestateProvider
	// contains filtered or unexported fields
}

AlphabetTraceProvider is a [TraceProvider] that provides claims for specific indices in the given trace.

func NewTraceProvider

func NewTraceProvider(state string, depth uint64) *AlphabetTraceProvider

NewTraceProvider returns a new [AlphabetProvider].

func (*AlphabetTraceProvider) Get

Get returns the claim value at the given index in the trace.

func (*AlphabetTraceProvider) GetStepData

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL