Versions in this module Expand all Collapse all v0 v0.1.0 Dec 20, 2023 Changes in this version + var BasicAny = &Any + var BasicBoolean = MakeBasic("boolean") + var BasicCons = MakeBasic("cons") + var BasicKeyword = MakeBasic("keyword") + var BasicList = MakeBasic("list") + var BasicNull = MakeBasic("null") + var BasicNumber = MakeBasic("number") + var BasicObject = MakeBasic("object") + var BasicProcedure = MakeBasic("procedure") + var BasicString = MakeBasic("string") + var BasicSymbol = MakeBasic("symbol") + var BasicUnion = MakeBasic("union") + var BasicVector = MakeBasic("vector") + func Accepts(left, right Type) bool + func Equal(l, r Type) bool + type AcceptsWith func(*Checker, Type) bool + type Any struct + func (*Any) Accepts(*Checker, Type) bool + func (a *Any) Equal(other Type) bool + type Applicable struct + func MakeApplicable(first Signature, rest ...Signature) *Applicable + func (a *Applicable) Accepts(c *Checker, other Type) bool + func (a *Applicable) Equal(other Type) bool + func (a *Applicable) Name() string + func (a *Applicable) Signatures() []Signature + type Basic struct + func MakeBasic(name string) *Basic + func (b *Basic) Accepts(_ *Checker, other Type) bool + func (b *Basic) Equal(other Type) bool + func (b *Basic) Kind() Kind + func (b *Basic) Name() string + type Checker struct + func Check(t Type) *Checker + func (c *Checker) Accepts(right Type) bool + func (c *Checker) AcceptsChild(left, right Type) bool + func (c *Checker) AcceptsChildWith(left, right Type, with AcceptsWith) bool + func (c *Checker) AcceptsWith(right Type, with AcceptsWith) bool + func (c *Checker) Receiver() Type + type Field struct + Name string + Value Type + type Kind uuid.UUID + type Object struct + func MakeObject(key Type, value Type) *Object + func (o *Object) Accepts(c *Checker, other Type) bool + func (o *Object) Equal(other Type) bool + func (o *Object) Key() Type + func (o *Object) Name() string + func (o *Object) Value() Type + type Pair struct + func (p *Pair) Accepts(c *Checker, other Type) bool + func (p *Pair) Car() Type + func (p *Pair) Cdr() Type + func (p *Pair) Equal(other Type) bool + func (p *Pair) Name() string + type Record struct + func MakeRecord(fields ...Field) *Record + func (r *Record) Accepts(c *Checker, other Type) bool + func (r *Record) Equal(other Type) bool + func (r *Record) Fields() []Field + func (r *Record) Name() string + type Signature struct + Params []Type + Result Type + TakesRest bool + type Type interface + Accepts func(*Checker, Type) bool + Equal func(Type) bool + Name func() string + func MakeCons(left, right Type) Type + func MakeListOf(elem Type) Type + func MakeTuple(elems ...Type) Type + func MakeUnion(first Type, rest ...Type) Type + func MakeVectorOf(elem Type) Type + type Union struct + func (u *Union) Accepts(c *Checker, other Type) bool + func (u *Union) Equal(other Type) bool + func (u *Union) Name() string + func (u *Union) Options() []Type