test

package
v0.0.0-...-13d83e7 Latest Latest
Warning

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

Go to latest
Published: Oct 17, 2024 License: Unlicense Imports: 4 Imported by: 0

Documentation

Overview

Package test contains helpers for testing parsers.

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ErrReaderAt

func ErrReaderAt(err error) io.ReaderAt

ErrReaderAt returns an io.ReaderAt with a ReadAt method that always returns err.

func ForceResult

func ForceResult(state gigaparsec.State[ForcedResult]) (gigaparsec.Result[ForcedResult, struct{}], error)

func SliceOfN

func SliceOfN[T any](value T, n int) []T

func StateIsAt

func StateIsAt[Input any](t test.T, s gigaparsec.State[Input], pos uint64)

Types

type ForcedResult

type ForcedResult struct{ Succeed, Consume bool }

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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