list

package
v0.0.7 Latest Latest
Warning

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

Go to latest
Published: Apr 12, 2022 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Conform added in v0.0.4

func Conform[A any, CA Class[A]](c CA) func(t *testing.T, x, y, z List[A])

Conform returns a function testing if the implementation abides by its laws.

func NewEqualFn added in v0.0.5

func NewEqualFn[A any](e eq.Class[A]) func(x, y List[A]) bool

NewEqualFn returns a list equality checking function given the eq.Class for the type A.

Types

type Class

type Class[A any] interface {
	monoid.Class[List[A]]
}

type List added in v0.0.4

type List[A any] []A

func (List[A]) DEmpty added in v0.0.6

func (l List[A]) DEmpty() bool

func (List[A]) DRest added in v0.0.4

func (l List[A]) DRest() data.Data[A]

func (List[A]) DValue added in v0.0.4

func (l List[A]) DValue() A

type Type

type Type[
	A any,
] struct {
	monoid.Type[List[A]]
}

func NewType

func NewType[
	A any,
]() Type[A]

Jump to

Keyboard shortcuts

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