Documentation ¶
Index ¶
- Constants
- Variables
- func AssertIOReader(obj Object, msg string) io.Reader
- func AssertIOWriter(obj Object, msg string) io.Writer
- func AssertInts(args []Object) (Int, Int)
- func CheckArity(args []Object, min int, max int)
- func CompareNumbers(x Number, y Number) int
- func EnsureIOWriter(args []Object, index int) io.Writer
- func EnsureRuneReader(args []Object, index int) io.RuneReader
- func ExtractDouble(args []Object, index int) float64
- func ExtractInt(args []Object, index int) int
- func ExtractRegex(args []Object, index int) *regexp.Regexp
- func ExtractString(args []Object, index int) string
- func ExtractStrings(args []Object, index int) []string
- func IsEqualOrImplements(abstractType *Type, concreteType *Type) bool
- func IsInstance(t *Type, obj Object) bool
- func IsSeq(obj Object) bool
- func IsSeqEqual(seq Seq, other interface{}) bool
- func IsSpecialSymbol(obj Object) bool
- func IsSymbol(obj Object) bool
- func IsVector(obj Object) bool
- func PanicArity(n int)
- func PanicOnErr(err error)
- func ProcessLinterData(dialect Dialect)
- func ProcessReader(reader *Reader, filename string, phase Phase) error
- func ReadConfig(filename string, workingDir string)
- func SeqCount(seq Seq) int
- func SeqToString(seq Seq, escape bool) string
- func SeqsEqual(seq1, seq2 Seq) bool
- func WarnOnUnusedNamespaces()
- func WarnOnUnusedVars()
- type ArrayMap
- func (m *ArrayMap) Add(key Object, value Object) bool
- func (m *ArrayMap) Assoc(key Object, value Object) Associative
- func (m *ArrayMap) Call(args []Object) Object
- func (m *ArrayMap) Clone() *ArrayMap
- func (m *ArrayMap) Conj(obj Object) Conjable
- func (m *ArrayMap) Count() int
- func (m *ArrayMap) Empty() Collection
- func (m *ArrayMap) EntryAt(key Object) *Vector
- func (m *ArrayMap) Equals(other interface{}) bool
- func (m *ArrayMap) Get(key Object) (bool, Object)
- func (m *ArrayMap) GetType() *Type
- func (m *ArrayMap) Hash() uint32
- func (m *ArrayMap) Iter() MapIterator
- func (m *ArrayMap) Keys() Seq
- func (m *ArrayMap) Merge(other Map) Map
- func (m *ArrayMap) Pprint(w io.Writer, indent int) int
- func (m *ArrayMap) Seq() Seq
- func (m *ArrayMap) Set(key Object, value Object)
- func (m *ArrayMap) ToString(escape bool) string
- func (m *ArrayMap) Vals() Seq
- func (x *ArrayMap) WithInfo(info *ObjectInfo) Object
- func (v *ArrayMap) WithMeta(meta Map) Object
- func (m *ArrayMap) Without(key Object) Map
- type ArrayMapIterator
- type ArrayMapSeq
- func (seq *ArrayMapSeq) Cons(obj Object) Seq
- func (seq *ArrayMapSeq) Equals(other interface{}) bool
- func (seq *ArrayMapSeq) First() Object
- func (seq *ArrayMapSeq) GetType() *Type
- func (seq *ArrayMapSeq) Hash() uint32
- func (seq *ArrayMapSeq) IsEmpty() bool
- func (seq *ArrayMapSeq) Pprint(w io.Writer, indent int) int
- func (seq *ArrayMapSeq) Rest() Seq
- func (seq *ArrayMapSeq) Seq() Seq
- func (seq *ArrayMapSeq) ToString(escape bool) string
- func (x *ArrayMapSeq) WithInfo(info *ObjectInfo) Object
- func (seq *ArrayMapSeq) WithMeta(meta Map) Object
- type ArrayNode
- type ArrayNodeIterator
- type ArrayNodeSeq
- func (s *ArrayNodeSeq) Cons(obj Object) Seq
- func (s *ArrayNodeSeq) Equals(other interface{}) bool
- func (s *ArrayNodeSeq) First() Object
- func (s *ArrayNodeSeq) GetType() *Type
- func (s *ArrayNodeSeq) Hash() uint32
- func (s *ArrayNodeSeq) IsEmpty() bool
- func (seq *ArrayNodeSeq) Pprint(w io.Writer, indent int) int
- func (s *ArrayNodeSeq) Rest() Seq
- func (s *ArrayNodeSeq) Seq() Seq
- func (s *ArrayNodeSeq) ToString(escape bool) string
- func (x *ArrayNodeSeq) WithInfo(info *ObjectInfo) Object
- func (s *ArrayNodeSeq) WithMeta(meta Map) Object
- type ArraySeq
- func (seq *ArraySeq) Cons(obj Object) Seq
- func (seq *ArraySeq) Equals(other interface{}) bool
- func (seq *ArraySeq) First() Object
- func (seq *ArraySeq) GetType() *Type
- func (seq *ArraySeq) Hash() uint32
- func (seq *ArraySeq) IsEmpty() bool
- func (seq *ArraySeq) Pprint(w io.Writer, indent int) int
- func (seq *ArraySeq) Rest() Seq
- func (seq *ArraySeq) Seq() Seq
- func (seq *ArraySeq) ToString(escape bool) string
- func (x *ArraySeq) WithInfo(info *ObjectInfo) Object
- func (seq *ArraySeq) WithMeta(meta Map) Object
- type Associative
- type Atom
- func (a *Atom) AlterMeta(fn *Fn, args []Object) Map
- func (a *Atom) Deref() Object
- func (a *Atom) Equals(other interface{}) bool
- func (a *Atom) GetInfo() *ObjectInfo
- func (a *Atom) GetType() *Type
- func (a *Atom) Hash() uint32
- func (a *Atom) ResetMeta(newMeta Map) Map
- func (a *Atom) ToString(escape bool) string
- func (a *Atom) WithInfo(info *ObjectInfo) Object
- func (a *Atom) WithMeta(meta Map) Object
- type BigFloat
- func (b *BigFloat) BigFloat() *big.Float
- func (b *BigFloat) BigInt() *big.Int
- func (bf *BigFloat) Compare(other Object) int
- func (b *BigFloat) Double() Double
- func (bf *BigFloat) Equals(other interface{}) bool
- func (bf *BigFloat) GetType() *Type
- func (bf *BigFloat) Hash() uint32
- func (b *BigFloat) Int() Int
- func (b *BigFloat) Ratio() *big.Rat
- func (bf *BigFloat) ToString(escape bool) string
- func (x *BigFloat) WithInfo(info *ObjectInfo) Object
- type BigFloatOps
- func (ops BigFloatOps) Add(x, y Number) Number
- func (ops BigFloatOps) Combine(other Ops) Ops
- func (ops BigFloatOps) Divide(x, y Number) Number
- func (ops BigFloatOps) Eq(x Number, y Number) bool
- func (ops BigFloatOps) Gt(x Number, y Number) bool
- func (ops BigFloatOps) Gte(x Number, y Number) bool
- func (ops BigFloatOps) IsZero(x Number) bool
- func (ops BigFloatOps) Lt(x Number, y Number) bool
- func (ops BigFloatOps) Lte(x Number, y Number) bool
- func (ops BigFloatOps) Multiply(x, y Number) Number
- func (ops BigFloatOps) Quotient(x, y Number) Number
- func (ops BigFloatOps) Rem(x, y Number) Number
- func (ops BigFloatOps) Subtract(x, y Number) Number
- type BigInt
- func (b *BigInt) BigFloat() *big.Float
- func (b *BigInt) BigInt() *big.Int
- func (bi *BigInt) Compare(other Object) int
- func (b *BigInt) Double() Double
- func (bi *BigInt) Equals(other interface{}) bool
- func (bi *BigInt) GetType() *Type
- func (bi *BigInt) Hash() uint32
- func (b *BigInt) Int() Int
- func (b *BigInt) Ratio() *big.Rat
- func (bi *BigInt) ToString(escape bool) string
- func (x *BigInt) WithInfo(info *ObjectInfo) Object
- type BigIntOps
- func (ops BigIntOps) Add(x, y Number) Number
- func (ops BigIntOps) Combine(other Ops) Ops
- func (ops BigIntOps) Divide(x, y Number) Number
- func (ops BigIntOps) Eq(x Number, y Number) bool
- func (ops BigIntOps) Gt(x Number, y Number) bool
- func (ops BigIntOps) Gte(x Number, y Number) bool
- func (ops BigIntOps) IsZero(x Number) bool
- func (ops BigIntOps) Lt(x Number, y Number) bool
- func (ops BigIntOps) Lte(x Number, y Number) bool
- func (ops BigIntOps) Multiply(x, y Number) Number
- func (ops BigIntOps) Quotient(x, y Number) Number
- func (ops BigIntOps) Rem(x, y Number) Number
- func (ops BigIntOps) Subtract(x, y Number) Number
- type Binding
- type BindingExpr
- type Bindings
- type BitmapIndexedNode
- type Bool
- type Box
- type Buffer
- type BufferedReader
- func (br *BufferedReader) Equals(other interface{}) bool
- func (br *BufferedReader) GetInfo() *ObjectInfo
- func (br *BufferedReader) GetType() *Type
- func (br *BufferedReader) Hash() uint32
- func (br *BufferedReader) ToString(escape bool) string
- func (br *BufferedReader) WithInfo(info *ObjectInfo) Object
- type CallExpr
- type Callable
- type Callstack
- type CatchExpr
- type Char
- type Collection
- type Comparable
- type Comparator
- type Conjable
- type ConsSeq
- func (seq *ConsSeq) Cons(obj Object) Seq
- func (seq *ConsSeq) Equals(other interface{}) bool
- func (seq *ConsSeq) First() Object
- func (seq *ConsSeq) GetType() *Type
- func (seq *ConsSeq) Hash() uint32
- func (seq *ConsSeq) IsEmpty() bool
- func (seq *ConsSeq) Pprint(w io.Writer, indent int) int
- func (seq *ConsSeq) Rest() Seq
- func (seq *ConsSeq) Seq() Seq
- func (seq *ConsSeq) ToString(escape bool) string
- func (x *ConsSeq) WithInfo(info *ObjectInfo) Object
- func (seq *ConsSeq) WithMeta(meta Map) Object
- type Counted
- type DefExpr
- type Delay
- func (d *Delay) Deref() Object
- func (d *Delay) Equals(other interface{}) bool
- func (d *Delay) Force() Object
- func (d *Delay) GetInfo() *ObjectInfo
- func (d *Delay) GetType() *Type
- func (d *Delay) Hash() uint32
- func (d *Delay) IsRealized() bool
- func (d *Delay) ToString(escape bool) string
- func (d *Delay) WithInfo(info *ObjectInfo) Object
- type Deref
- type Dialect
- type DoExpr
- type Double
- func (d Double) BigFloat() *big.Float
- func (d Double) BigInt() *big.Int
- func (d Double) Compare(other Object) int
- func (d Double) Double() Double
- func (d Double) Equals(other interface{}) bool
- func (d Double) GetType() *Type
- func (d Double) Hash() uint32
- func (d Double) Int() Int
- func (d Double) Native() interface{}
- func (d Double) Ratio() *big.Rat
- func (d Double) ToString(escape bool) string
- func (x Double) WithInfo(info *ObjectInfo) Object
- type DoubleOps
- func (ops DoubleOps) Add(x, y Number) Number
- func (ops DoubleOps) Combine(other Ops) Ops
- func (ops DoubleOps) Divide(x, y Number) Number
- func (ops DoubleOps) Eq(x Number, y Number) bool
- func (ops DoubleOps) Gt(x Number, y Number) bool
- func (ops DoubleOps) Gte(x Number, y Number) bool
- func (ops DoubleOps) IsZero(x Number) bool
- func (ops DoubleOps) Lt(x Number, y Number) bool
- func (ops DoubleOps) Lte(x Number, y Number) bool
- func (ops DoubleOps) Multiply(x, y Number) Number
- func (ops DoubleOps) Quotient(x, y Number) Number
- func (ops DoubleOps) Rem(x, y Number) Number
- func (ops DoubleOps) Subtract(x, y Number) Number
- type EmptyMapIterator
- type Env
- func (env *Env) CurrentNamespace() *Namespace
- func (env *Env) EnsureNamespace(sym Symbol) *Namespace
- func (env *Env) FindNamespace(s Symbol) *Namespace
- func (env *Env) NamespaceFor(ns *Namespace, s Symbol) *Namespace
- func (env *Env) RemoveNamespace(s Symbol) *Namespace
- func (env *Env) Resolve(s Symbol) (*Var, bool)
- func (env *Env) ResolveIn(n *Namespace, s Symbol) (*Var, bool)
- func (env *Env) ResolveSymbol(s Symbol) Symbol
- type Equality
- type Error
- type EvalError
- func (err *EvalError) Equals(other interface{}) bool
- func (err *EvalError) Error() string
- func (err *EvalError) GetInfo() *ObjectInfo
- func (err *EvalError) GetType() *Type
- func (err *EvalError) Hash() uint32
- func (err *EvalError) ToString(escape bool) string
- func (err *EvalError) WithInfo(info *ObjectInfo) Object
- type ExInfo
- type Expr
- type File
- type Fn
- func (fn *Fn) Call(args []Object) Object
- func (fn *Fn) Compare(a, b Object) int
- func (fn *Fn) Equals(other interface{}) bool
- func (fn *Fn) GetType() *Type
- func (fn *Fn) Hash() uint32
- func (fn *Fn) ToString(escape bool) string
- func (x *Fn) WithInfo(info *ObjectInfo) Object
- func (fn *Fn) WithMeta(meta Map) Object
- type FnArityExpr
- type FnExpr
- type Frame
- type Gettable
- type HashCollisionNode
- type HashMap
- func (m *HashMap) Assoc(key, val Object) Associative
- func (m *HashMap) Call(args []Object) Object
- func (m *HashMap) Conj(obj Object) Conjable
- func (m *HashMap) Count() int
- func (m *HashMap) Empty() Collection
- func (m *HashMap) EntryAt(key Object) *Vector
- func (m *HashMap) Equals(other interface{}) bool
- func (m *HashMap) Get(key Object) (bool, Object)
- func (m *HashMap) GetType() *Type
- func (m *HashMap) Hash() uint32
- func (m *HashMap) Iter() MapIterator
- func (m *HashMap) Keys() Seq
- func (m *HashMap) Merge(other Map) Map
- func (m *HashMap) Pprint(w io.Writer, indent int) int
- func (m *HashMap) Seq() Seq
- func (m *HashMap) ToString(escape bool) string
- func (m *HashMap) Vals() Seq
- func (x *HashMap) WithInfo(info *ObjectInfo) Object
- func (m *HashMap) WithMeta(meta Map) Object
- func (m *HashMap) Without(key Object) Map
- type IfExpr
- type Indexed
- type InfoHolder
- type Int
- func (i Int) BigFloat() *big.Float
- func (i Int) BigInt() *big.Int
- func (i Int) Compare(other Object) int
- func (i Int) Double() Double
- func (i Int) Equals(other interface{}) bool
- func (i Int) GetType() *Type
- func (i Int) Hash() uint32
- func (i Int) Int() Int
- func (i Int) Native() interface{}
- func (i Int) Ratio() *big.Rat
- func (i Int) ToString(escape bool) string
- func (x Int) WithInfo(info *ObjectInfo) Object
- type IntOps
- func (ops IntOps) Add(x, y Number) Number
- func (ops IntOps) Combine(other Ops) Ops
- func (ops IntOps) Divide(x, y Number) Number
- func (ops IntOps) Eq(x Number, y Number) bool
- func (ops IntOps) Gt(x Number, y Number) bool
- func (ops IntOps) Gte(x Number, y Number) bool
- func (ops IntOps) IsZero(x Number) bool
- func (ops IntOps) Lt(x Number, y Number) bool
- func (ops IntOps) Lte(x Number, y Number) bool
- func (ops IntOps) Multiply(x, y Number) Number
- func (ops IntOps) Quotient(x, y Number) Number
- func (ops IntOps) Rem(x, y Number) Number
- func (ops IntOps) Subtract(x, y Number) Number
- type KVReduce
- type Keyword
- func (k Keyword) Call(args []Object) Object
- func (k Keyword) Compare(other Object) int
- func (k Keyword) Equals(other interface{}) bool
- func (k Keyword) GetType() *Type
- func (k Keyword) Hash() uint32
- func (k Keyword) Name() string
- func (k Keyword) Namespace() string
- func (k Keyword) ToString(escape bool) string
- func (x Keyword) WithInfo(info *ObjectInfo) Object
- type Keywords
- type LazySeq
- func (seq *LazySeq) Cons(obj Object) Seq
- func (seq *LazySeq) Equals(other interface{}) bool
- func (seq *LazySeq) First() Object
- func (seq *LazySeq) GetType() *Type
- func (seq *LazySeq) Hash() uint32
- func (seq *LazySeq) IsEmpty() bool
- func (seq *LazySeq) IsRealized() bool
- func (seq *LazySeq) Pprint(w io.Writer, indent int) int
- func (seq *LazySeq) Rest() Seq
- func (seq *LazySeq) Seq() Seq
- func (seq *LazySeq) ToString(escape bool) string
- func (x *LazySeq) WithInfo(info *ObjectInfo) Object
- func (seq *LazySeq) WithMeta(meta Map) Object
- type LetExpr
- type LineRuneReader
- type List
- func (list *List) Conj(obj Object) Conjable
- func (list *List) Cons(obj Object) Seq
- func (list *List) Count() int
- func (list *List) Empty() Collection
- func (list *List) Equals(other interface{}) bool
- func (list *List) First() Object
- func (list *List) Forth() Object
- func (list *List) GetType() *Type
- func (list *List) Hash() uint32
- func (list *List) IsEmpty() bool
- func (list *List) Peek() Object
- func (list *List) Pop() Stack
- func (seq *List) Pprint(w io.Writer, indent int) int
- func (list *List) Rest() Seq
- func (list *List) Second() Object
- func (list *List) Seq() Seq
- func (list *List) Third() Object
- func (list *List) ToString(escape bool) string
- func (x *List) WithInfo(info *ObjectInfo) Object
- func (list *List) WithMeta(meta Map) Object
- type LiteralExpr
- type LocalEnv
- type LoopExpr
- type MacroCallExpr
- type Map
- type MapExpr
- type MapIterator
- type MapSet
- func (set *MapSet) Add(obj Object) bool
- func (set *MapSet) Call(args []Object) Object
- func (set *MapSet) Conj(obj Object) Conjable
- func (set *MapSet) Count() int
- func (set *MapSet) Disjoin(key Object) Set
- func (set *MapSet) Empty() Collection
- func (set *MapSet) Equals(other interface{}) bool
- func (set *MapSet) Get(key Object) (bool, Object)
- func (seq *MapSet) GetType() *Type
- func (set *MapSet) Hash() uint32
- func (set *MapSet) Pprint(w io.Writer, indent int) int
- func (set *MapSet) Seq() Seq
- func (set *MapSet) ToString(escape bool) string
- func (x *MapSet) WithInfo(info *ObjectInfo) Object
- func (v *MapSet) WithMeta(meta Map) Object
- type MappingSeq
- func (seq *MappingSeq) Cons(obj Object) Seq
- func (seq *MappingSeq) Equals(other interface{}) bool
- func (seq *MappingSeq) First() Object
- func (seq *MappingSeq) GetType() *Type
- func (seq *MappingSeq) Hash() uint32
- func (seq *MappingSeq) IsEmpty() bool
- func (seq *MappingSeq) Pprint(w io.Writer, indent int) int
- func (seq *MappingSeq) Rest() Seq
- func (seq *MappingSeq) Seq() Seq
- func (seq *MappingSeq) ToString(escape bool) string
- func (x *MappingSeq) WithInfo(info *ObjectInfo) Object
- func (seq *MappingSeq) WithMeta(meta Map) Object
- type Meta
- type MetaExpr
- type MetaHolder
- type Named
- type Namespace
- func (ns *Namespace) AddAlias(alias Symbol, namespace *Namespace)
- func (ns *Namespace) AlterMeta(fn *Fn, args []Object) Map
- func (ns *Namespace) Equals(other interface{}) bool
- func (ns *Namespace) GetInfo() *ObjectInfo
- func (ns *Namespace) GetType() *Type
- func (ns *Namespace) Hash() uint32
- func (ns *Namespace) Intern(sym Symbol) *Var
- func (ns *Namespace) InternVar(name string, val Object, meta Map) *Var
- func (ns *Namespace) Refer(sym Symbol, vr *Var) *Var
- func (ns *Namespace) ReferAll(other *Namespace)
- func (ns *Namespace) ResetMeta(newMeta Map) Map
- func (ns *Namespace) Resolve(name string) *Var
- func (ns *Namespace) ToString(escape bool) string
- func (ns *Namespace) WithInfo(info *ObjectInfo) Object
- func (ns *Namespace) WithMeta(meta Map) Object
- type Native
- type Nil
- func (n Nil) Assoc(key, value Object) Associative
- func (n Nil) Conj(obj Object) Conjable
- func (n Nil) Cons(obj Object) Seq
- func (n Nil) Count() int
- func (n Nil) Disjoin(key Object) Set
- func (n Nil) EntryAt(key Object) *Vector
- func (n Nil) Equals(other interface{}) bool
- func (n Nil) First() Object
- func (n Nil) Get(key Object) (bool, Object)
- func (n Nil) GetType() *Type
- func (n Nil) Hash() uint32
- func (n Nil) IsEmpty() bool
- func (n Nil) Iter() MapIterator
- func (n Nil) Keys() Seq
- func (n Nil) Merge(other Map) Map
- func (n Nil) Rest() Seq
- func (n Nil) Seq() Seq
- func (n Nil) ToString(escape bool) string
- func (n Nil) Vals() Seq
- func (x Nil) WithInfo(info *ObjectInfo) Object
- func (n Nil) Without(key Object) Map
- type Node
- type NodeIterator
- type NodeSeq
- func (s *NodeSeq) Cons(obj Object) Seq
- func (s *NodeSeq) Equals(other interface{}) bool
- func (s *NodeSeq) First() Object
- func (s *NodeSeq) GetType() *Type
- func (s *NodeSeq) Hash() uint32
- func (s *NodeSeq) IsEmpty() bool
- func (seq *NodeSeq) Pprint(w io.Writer, indent int) int
- func (s *NodeSeq) Rest() Seq
- func (s *NodeSeq) Seq() Seq
- func (s *NodeSeq) ToString(escape bool) string
- func (x *NodeSeq) WithInfo(info *ObjectInfo) Object
- func (s *NodeSeq) WithMeta(meta Map) Object
- type Number
- type Object
- func DeriveReadObject(base Object, obj Object) Object
- func Eval(expr Expr, env *LocalEnv) Object
- func ExtractObject(args []Object, index int) Object
- func Forth(seq Seq) Object
- func MakeReadObject(reader *Reader, obj Object) Object
- func Read(reader *Reader) (Object, bool)
- func Second(seq Seq) Object
- func SeqNth(seq Seq, n int) Object
- func SeqTryNth(seq Seq, n int, d Object) Object
- func Third(seq Seq) Object
- func ToSlice(seq Seq) []Object
- func TryEval(expr Expr) (obj Object, err error)
- func TryRead(reader *Reader) (obj Object, err error)
- type ObjectInfo
- type Ops
- type Pair
- type ParseContext
- func (ctx *ParseContext) GetLocalBinding(sym Symbol) *Binding
- func (ctx *ParseContext) GetLoopBindings() []Symbol
- func (ctx *ParseContext) PopLocalFrame()
- func (ctx *ParseContext) PopLoopBindings()
- func (ctx *ParseContext) PushEmptyLocalFrame()
- func (ctx *ParseContext) PushLocalFrame(names []Symbol)
- func (ctx *ParseContext) PushLoopBindings(bindings []Symbol)
- type ParseError
- func (err *ParseError) Equals(other interface{}) bool
- func (err ParseError) Error() string
- func (err *ParseError) GetInfo() *ObjectInfo
- func (err *ParseError) GetType() *Type
- func (err *ParseError) Hash() uint32
- func (err *ParseError) ToString(escape bool) string
- func (err *ParseError) WithInfo(info *ObjectInfo) Object
- type Pending
- type Phase
- type Position
- type Pprinter
- type Printer
- type Proc
- func (p Proc) Call(args []Object) Object
- func (p Proc) Compare(a, b Object) int
- func (p Proc) Equals(other interface{}) bool
- func (p Proc) GetInfo() *ObjectInfo
- func (p Proc) GetType() *Type
- func (p Proc) Hash() uint32
- func (p Proc) ToString(escape bool) string
- func (p Proc) WithInfo(*ObjectInfo) Object
- type Ratio
- func (r *Ratio) BigFloat() *big.Float
- func (r *Ratio) BigInt() *big.Int
- func (rat *Ratio) Compare(other Object) int
- func (r *Ratio) Double() Double
- func (rat *Ratio) Equals(other interface{}) bool
- func (rat *Ratio) GetType() *Type
- func (rat *Ratio) Hash() uint32
- func (r *Ratio) Int() Int
- func (r *Ratio) Ratio() *big.Rat
- func (rat *Ratio) ToString(escape bool) string
- func (x *Ratio) WithInfo(info *ObjectInfo) Object
- type RatioOps
- func (ops RatioOps) Add(x, y Number) Number
- func (ops RatioOps) Combine(other Ops) Ops
- func (ops RatioOps) Divide(x, y Number) Number
- func (ops RatioOps) Eq(x Number, y Number) bool
- func (ops RatioOps) Gt(x Number, y Number) bool
- func (ops RatioOps) Gte(x Number, y Number) bool
- func (ops RatioOps) IsZero(x Number) bool
- func (ops RatioOps) Lt(x Number, y Number) bool
- func (ops RatioOps) Lte(x Number, y Number) bool
- func (ops RatioOps) Multiply(x, y Number) Number
- func (ops RatioOps) Quotient(x, y Number) Number
- func (ops RatioOps) Rem(x, y Number) Number
- func (ops RatioOps) Subtract(x, y Number) Number
- type ReadError
- type ReadFunc
- type Reader
- type RecurBindings
- type RecurExpr
- type Ref
- type Regex
- type Reversible
- type RuneWindow
- type Runtime
- type Seq
- type SeqIterator
- type Seqable
- type Sequential
- type Set
- type SetExpr
- type SortableSlice
- type Stack
- type Str
- type String
- func (s String) Compare(other Object) int
- func (s String) Count() int
- func (s String) Equals(other interface{}) bool
- func (s String) GetType() *Type
- func (s String) Hash() uint32
- func (s String) Native() interface{}
- func (s String) Nth(i int) Object
- func (s String) Seq() Seq
- func (s String) ToString(escape bool) string
- func (s String) TryNth(i int, d Object) Object
- func (x String) WithInfo(info *ObjectInfo) Object
- type StringPool
- type Symbol
- func (s Symbol) Compare(other Object) int
- func (s Symbol) Equals(other interface{}) bool
- func (s Symbol) GetType() *Type
- func (s Symbol) Hash() uint32
- func (s Symbol) Name() string
- func (s Symbol) Namespace() string
- func (s Symbol) ToString(escape bool) string
- func (x Symbol) WithInfo(info *ObjectInfo) Object
- func (sym Symbol) WithMeta(meta Map) Object
- type Symbols
- type ThrowExpr
- type Traceable
- type TryExpr
- type Type
- type Types
- type Var
- func (v *Var) AlterMeta(fn *Fn, args []Object) Map
- func (v *Var) Call(args []Object) Object
- func (v *Var) Deref() Object
- func (v *Var) Equals(other interface{}) bool
- func (v *Var) GetType() *Type
- func (v *Var) Hash() uint32
- func (v *Var) ResetMeta(newMeta Map) Map
- func (v *Var) Resolve() Object
- func (v *Var) ToString(escape bool) string
- func (x *Var) WithInfo(info *ObjectInfo) Object
- func (v *Var) WithMeta(meta Map) Object
- type VarRefExpr
- type Vector
- func (v *Vector) Assoc(key, val Object) Associative
- func (v *Vector) Call(args []Object) Object
- func (v *Vector) Compare(other Object) int
- func (v *Vector) Conj(obj Object) Conjable
- func (v *Vector) Conjoin(obj Object) *Vector
- func (v *Vector) Count() int
- func (v *Vector) Empty() Collection
- func (v *Vector) EntryAt(key Object) *Vector
- func (v *Vector) Equals(other interface{}) bool
- func (v *Vector) Get(key Object) (bool, Object)
- func (v *Vector) GetType() *Type
- func (v *Vector) Hash() uint32
- func (v *Vector) Nth(i int) Object
- func (v *Vector) Peek() Object
- func (v *Vector) Pop() Stack
- func (v *Vector) Pprint(w io.Writer, indent int) int
- func (v *Vector) Rseq() Seq
- func (v *Vector) Seq() Seq
- func (v *Vector) ToString(escape bool) string
- func (v *Vector) TryNth(i int, d Object) Object
- func (x *Vector) WithInfo(info *ObjectInfo) Object
- func (v *Vector) WithMeta(meta Map) Object
- type VectorExpr
- type VectorRSeq
- func (vseq *VectorRSeq) Cons(obj Object) Seq
- func (vseq *VectorRSeq) Equals(other interface{}) bool
- func (vseq *VectorRSeq) First() Object
- func (vseq *VectorRSeq) GetType() *Type
- func (vseq *VectorRSeq) Hash() uint32
- func (vseq *VectorRSeq) IsEmpty() bool
- func (seq *VectorRSeq) Pprint(w io.Writer, indent int) int
- func (vseq *VectorRSeq) Rest() Seq
- func (seq *VectorRSeq) Seq() Seq
- func (vseq *VectorRSeq) ToString(escape bool) string
- func (x *VectorRSeq) WithInfo(info *ObjectInfo) Object
- func (vseq *VectorRSeq) WithMeta(meta Map) Object
- type VectorSeq
- func (vseq *VectorSeq) Cons(obj Object) Seq
- func (vseq *VectorSeq) Equals(other interface{}) bool
- func (vseq *VectorSeq) First() Object
- func (vseq *VectorSeq) GetType() *Type
- func (vseq *VectorSeq) Hash() uint32
- func (vseq *VectorSeq) IsEmpty() bool
- func (seq *VectorSeq) Pprint(w io.Writer, indent int) int
- func (vseq *VectorSeq) Rest() Seq
- func (seq *VectorSeq) Seq() Seq
- func (vseq *VectorSeq) ToString(escape bool) string
- func (x *VectorSeq) WithInfo(info *ObjectInfo) Object
- func (vseq *VectorSeq) WithMeta(meta Map) Object
- type Warnings
Constants ¶
View Source
const EOF = -1
View Source
const MAX_INT = int(^uint(0) >> 1)
View Source
const MAX_RUNE = int(^uint32(0) >> 1)
View Source
const MIN_INT = -MAX_INT - 1
View Source
const MIN_RUNE = -MAX_RUNE - 1
View Source
const VERSION = "v0.8.9"
Variables ¶
View Source
var ( INT_OPS = IntOps{} DOUBLE_OPS = DoubleOps{} BIGINT_OPS = BigIntOps{} BIGFLOAT_OPS = BigFloatOps{} RATIO_OPS = RatioOps{} )
View Source
var ( GLOBAL_ENV = NewEnv(MakeSymbol("user"), os.Stdout, os.Stdin, os.Stderr) LOCAL_BINDINGS *Bindings = nil SPECIAL_SYMBOLS = make(map[*string]bool) KNOWN_MACROS *Var REQUIRE_VAR *Var ALIAS_VAR *Var CREATE_NS_VAR *Var WARNINGS = Warnings{} KEYWORDS = Keywords{ // contains filtered or unexported fields } SYMBOLS = Symbols{ // contains filtered or unexported fields } STR = Str{ // contains filtered or unexported fields } )
View Source
var ( ARGS map[int]Symbol GENSYM int )
View Source
var (
EmptyHashMap = &HashMap{}
)
View Source
var EmptyList = NewList(Nil{}, nil)
View Source
var EmptyVector = &Vector{ count: 0, shift: 5, root: empty_node, tail: make([]interface{}, 0, 32), }
View Source
var (
HASHMAP_THRESHOLD int = 16
)
View Source
var LINTER_MODE bool = false
View Source
var NIL = Nil{}
View Source
var TYPES = map[*string]*Type{}
Functions ¶
func AssertInts ¶
func CheckArity ¶
func CompareNumbers ¶
func EnsureRuneReader ¶ added in v0.8.8
func EnsureRuneReader(args []Object, index int) io.RuneReader
func ExtractDouble ¶ added in v0.8.9
func ExtractInt ¶ added in v0.8.0
func ExtractString ¶ added in v0.8.0
func ExtractStrings ¶ added in v0.8.0
func IsEqualOrImplements ¶ added in v0.8.1
func IsInstance ¶
func IsSeqEqual ¶
func IsSpecialSymbol ¶
func PanicArity ¶ added in v0.8.0
func PanicArity(n int)
func PanicOnErr ¶ added in v0.8.9
func PanicOnErr(err error)
func ProcessLinterData ¶ added in v0.6.0
func ProcessLinterData(dialect Dialect)
func ReadConfig ¶ added in v0.8.0
func SeqToString ¶
func WarnOnUnusedNamespaces ¶ added in v0.7.2
func WarnOnUnusedNamespaces()
func WarnOnUnusedVars ¶ added in v0.7.2
func WarnOnUnusedVars()
Types ¶
type ArrayMap ¶
type ArrayMap struct { InfoHolder MetaHolder // contains filtered or unexported fields }
func EmptyArrayMap ¶
func EmptyArrayMap() *ArrayMap
func (*ArrayMap) Empty ¶
func (m *ArrayMap) Empty() Collection
func (*ArrayMap) Iter ¶
func (m *ArrayMap) Iter() MapIterator
func (*ArrayMap) WithInfo ¶
func (x *ArrayMap) WithInfo(info *ObjectInfo) Object
type ArrayMapIterator ¶
type ArrayMapIterator struct {
// contains filtered or unexported fields
}
func (*ArrayMapIterator) HasNext ¶
func (iter *ArrayMapIterator) HasNext() bool
func (*ArrayMapIterator) Next ¶
func (iter *ArrayMapIterator) Next() *Pair
type ArrayMapSeq ¶
type ArrayMapSeq struct { InfoHolder MetaHolder // contains filtered or unexported fields }
func (*ArrayMapSeq) Cons ¶
func (seq *ArrayMapSeq) Cons(obj Object) Seq
func (*ArrayMapSeq) Equals ¶
func (seq *ArrayMapSeq) Equals(other interface{}) bool
func (*ArrayMapSeq) First ¶
func (seq *ArrayMapSeq) First() Object
func (*ArrayMapSeq) GetType ¶
func (seq *ArrayMapSeq) GetType() *Type
func (*ArrayMapSeq) Hash ¶
func (seq *ArrayMapSeq) Hash() uint32
func (*ArrayMapSeq) IsEmpty ¶
func (seq *ArrayMapSeq) IsEmpty() bool
func (*ArrayMapSeq) Pprint ¶ added in v0.8.8
func (seq *ArrayMapSeq) Pprint(w io.Writer, indent int) int
func (*ArrayMapSeq) Rest ¶
func (seq *ArrayMapSeq) Rest() Seq
func (*ArrayMapSeq) Seq ¶
func (seq *ArrayMapSeq) Seq() Seq
func (*ArrayMapSeq) ToString ¶
func (seq *ArrayMapSeq) ToString(escape bool) string
func (*ArrayMapSeq) WithInfo ¶
func (x *ArrayMapSeq) WithInfo(info *ObjectInfo) Object
func (*ArrayMapSeq) WithMeta ¶
func (seq *ArrayMapSeq) WithMeta(meta Map) Object
type ArrayNodeIterator ¶
type ArrayNodeIterator struct {
// contains filtered or unexported fields
}
func (*ArrayNodeIterator) HasNext ¶
func (iter *ArrayNodeIterator) HasNext() bool
func (*ArrayNodeIterator) Next ¶
func (iter *ArrayNodeIterator) Next() *Pair
type ArrayNodeSeq ¶
type ArrayNodeSeq struct { InfoHolder MetaHolder // contains filtered or unexported fields }
func (*ArrayNodeSeq) Cons ¶
func (s *ArrayNodeSeq) Cons(obj Object) Seq
func (*ArrayNodeSeq) Equals ¶
func (s *ArrayNodeSeq) Equals(other interface{}) bool
func (*ArrayNodeSeq) First ¶
func (s *ArrayNodeSeq) First() Object
func (*ArrayNodeSeq) GetType ¶
func (s *ArrayNodeSeq) GetType() *Type
func (*ArrayNodeSeq) Hash ¶
func (s *ArrayNodeSeq) Hash() uint32
func (*ArrayNodeSeq) IsEmpty ¶
func (s *ArrayNodeSeq) IsEmpty() bool
func (*ArrayNodeSeq) Pprint ¶ added in v0.8.8
func (seq *ArrayNodeSeq) Pprint(w io.Writer, indent int) int
func (*ArrayNodeSeq) Rest ¶
func (s *ArrayNodeSeq) Rest() Seq
func (*ArrayNodeSeq) Seq ¶
func (s *ArrayNodeSeq) Seq() Seq
func (*ArrayNodeSeq) ToString ¶
func (s *ArrayNodeSeq) ToString(escape bool) string
func (*ArrayNodeSeq) WithInfo ¶
func (x *ArrayNodeSeq) WithInfo(info *ObjectInfo) Object
func (*ArrayNodeSeq) WithMeta ¶
func (s *ArrayNodeSeq) WithMeta(meta Map) Object
type ArraySeq ¶
type ArraySeq struct { InfoHolder MetaHolder // contains filtered or unexported fields }
func ArraySeqFromArrayMap ¶
func (*ArraySeq) WithInfo ¶
func (x *ArraySeq) WithInfo(info *ObjectInfo) Object
type Associative ¶
type Associative interface { Conjable Gettable EntryAt(key Object) *Vector Assoc(key, val Object) Associative }
func AssertAssociative ¶
func AssertAssociative(obj Object, msg string) Associative
func EnsureAssociative ¶
func EnsureAssociative(args []Object, index int) Associative
type Atom ¶
type Atom struct { MetaHolder // contains filtered or unexported fields }
func AssertAtom ¶
func EnsureAtom ¶
func (*Atom) GetInfo ¶
func (a *Atom) GetInfo() *ObjectInfo
func (*Atom) WithInfo ¶
func (a *Atom) WithInfo(info *ObjectInfo) Object
type BigFloat ¶
type BigFloat struct { InfoHolder // contains filtered or unexported fields }
func (*BigFloat) WithInfo ¶
func (x *BigFloat) WithInfo(info *ObjectInfo) Object
type BigFloatOps ¶
type BigFloatOps struct{}
func (BigFloatOps) Add ¶
func (ops BigFloatOps) Add(x, y Number) Number
func (BigFloatOps) Combine ¶
func (ops BigFloatOps) Combine(other Ops) Ops
func (BigFloatOps) Divide ¶
func (ops BigFloatOps) Divide(x, y Number) Number
func (BigFloatOps) IsZero ¶
func (ops BigFloatOps) IsZero(x Number) bool
func (BigFloatOps) Multiply ¶
func (ops BigFloatOps) Multiply(x, y Number) Number
func (BigFloatOps) Quotient ¶
func (ops BigFloatOps) Quotient(x, y Number) Number
func (BigFloatOps) Rem ¶
func (ops BigFloatOps) Rem(x, y Number) Number
func (BigFloatOps) Subtract ¶
func (ops BigFloatOps) Subtract(x, y Number) Number
type BigInt ¶
type BigInt struct { InfoHolder // contains filtered or unexported fields }
func (*BigInt) WithInfo ¶
func (x *BigInt) WithInfo(info *ObjectInfo) Object
type BindingExpr ¶
type BindingExpr struct { Position // contains filtered or unexported fields }
func (*BindingExpr) Dump ¶ added in v0.8.2
func (expr *BindingExpr) Dump(pos bool) Map
func (*BindingExpr) Eval ¶
func (expr *BindingExpr) Eval(env *LocalEnv) Object
func (*BindingExpr) InferType ¶ added in v0.8.2
func (expr *BindingExpr) InferType() *Type
type Bindings ¶
type Bindings struct {
// contains filtered or unexported fields
}
func (*Bindings) AddBinding ¶ added in v0.8.4
func (*Bindings) GetBinding ¶ added in v0.8.4
type BitmapIndexedNode ¶
type BitmapIndexedNode struct {
// contains filtered or unexported fields
}
type Bool ¶
type Bool struct { InfoHolder B bool }
func AssertBool ¶
func EnsureBool ¶
func (Bool) WithInfo ¶
func (x Bool) WithInfo(info *ObjectInfo) Object
type Buffer ¶
func (*Buffer) GetInfo ¶
func (b *Buffer) GetInfo() *ObjectInfo
func (*Buffer) WithInfo ¶
func (b *Buffer) WithInfo(info *ObjectInfo) Object
type BufferedReader ¶ added in v0.8.8
func (*BufferedReader) Equals ¶ added in v0.8.8
func (br *BufferedReader) Equals(other interface{}) bool
func (*BufferedReader) GetInfo ¶ added in v0.8.8
func (br *BufferedReader) GetInfo() *ObjectInfo
func (*BufferedReader) GetType ¶ added in v0.8.8
func (br *BufferedReader) GetType() *Type
func (*BufferedReader) Hash ¶ added in v0.8.8
func (br *BufferedReader) Hash() uint32
func (*BufferedReader) ToString ¶ added in v0.8.8
func (br *BufferedReader) ToString(escape bool) string
func (*BufferedReader) WithInfo ¶ added in v0.8.8
func (br *BufferedReader) WithInfo(info *ObjectInfo) Object
type Char ¶
type Char struct { InfoHolder Ch rune }
func AssertChar ¶
func EnsureChar ¶
func (Char) WithInfo ¶
func (x Char) WithInfo(info *ObjectInfo) Object
type Collection ¶
type Collection interface { Object Counted Seqable Empty() Collection }
type Comparable ¶
func AssertComparable ¶
func AssertComparable(obj Object, msg string) Comparable
func EnsureComparable ¶
func EnsureComparable(args []Object, index int) Comparable
type Comparator ¶
func AssertComparator ¶
func AssertComparator(obj Object, msg string) Comparator
func EnsureComparator ¶
func EnsureComparator(args []Object, index int) Comparator
type ConsSeq ¶
type ConsSeq struct { InfoHolder MetaHolder // contains filtered or unexported fields }
func (*ConsSeq) WithInfo ¶
func (x *ConsSeq) WithInfo(info *ObjectInfo) Object
type Delay ¶
type Delay struct {
// contains filtered or unexported fields
}
func (*Delay) GetInfo ¶
func (d *Delay) GetInfo() *ObjectInfo
func (*Delay) IsRealized ¶
func (*Delay) WithInfo ¶
func (d *Delay) WithInfo(info *ObjectInfo) Object
type Double ¶
type Double struct { InfoHolder D float64 }
func AssertDouble ¶ added in v0.8.9
func EnsureDouble ¶ added in v0.8.9
func MakeDouble ¶
func (Double) WithInfo ¶
func (x Double) WithInfo(info *ObjectInfo) Object
type EmptyMapIterator ¶
type EmptyMapIterator struct { }
func (*EmptyMapIterator) HasNext ¶
func (iter *EmptyMapIterator) HasNext() bool
func (*EmptyMapIterator) Next ¶
func (iter *EmptyMapIterator) Next() *Pair
type Env ¶
type Env struct { Namespaces map[*string]*Namespace CoreNamespace *Namespace Features Set // contains filtered or unexported fields }
func (*Env) CurrentNamespace ¶
func (*Env) EnsureNamespace ¶
func (*Env) FindNamespace ¶
func (*Env) RemoveNamespace ¶
func (*Env) ResolveSymbol ¶
type EvalError ¶
type EvalError struct {
// contains filtered or unexported fields
}
func (*EvalError) GetInfo ¶
func (err *EvalError) GetInfo() *ObjectInfo
func (*EvalError) WithInfo ¶
func (err *EvalError) WithInfo(info *ObjectInfo) Object
type ExInfo ¶
type ExInfo struct { ArrayMap // contains filtered or unexported fields }
func (*ExInfo) WithInfo ¶
func (x *ExInfo) WithInfo(info *ObjectInfo) Object
type Expr ¶
type Expr interface { Eval(env *LocalEnv) Object InferType() *Type Pos() Position Dump(includePosition bool) Map }
func Parse ¶
func Parse(obj Object, ctx *ParseContext) Expr
type File ¶
func (*File) GetInfo ¶
func (f *File) GetInfo() *ObjectInfo
func (*File) WithInfo ¶
func (f *File) WithInfo(info *ObjectInfo) Object
type Fn ¶
type Fn struct { InfoHolder MetaHolder // contains filtered or unexported fields }
func (*Fn) WithInfo ¶
func (x *Fn) WithInfo(info *ObjectInfo) Object
type FnArityExpr ¶
type FnArityExpr struct { Position // contains filtered or unexported fields }
func (*FnArityExpr) Dump ¶ added in v0.8.2
func (expr *FnArityExpr) Dump(pos bool) Map
func (*FnArityExpr) Eval ¶ added in v0.8.2
func (expr *FnArityExpr) Eval(env *LocalEnv) Object
func (*FnArityExpr) InferType ¶ added in v0.8.2
func (expr *FnArityExpr) InferType() *Type
type HashCollisionNode ¶
type HashCollisionNode struct {
// contains filtered or unexported fields
}
type HashMap ¶
type HashMap struct { InfoHolder MetaHolder // contains filtered or unexported fields }
func NewHashMap ¶
func (*HashMap) Assoc ¶
func (m *HashMap) Assoc(key, val Object) Associative
func (*HashMap) Empty ¶
func (m *HashMap) Empty() Collection
func (*HashMap) Iter ¶
func (m *HashMap) Iter() MapIterator
func (*HashMap) WithInfo ¶
func (x *HashMap) WithInfo(info *ObjectInfo) Object
type InfoHolder ¶
type InfoHolder struct {
// contains filtered or unexported fields
}
func (InfoHolder) GetInfo ¶
func (i InfoHolder) GetInfo() *ObjectInfo
type Int ¶
type Int struct { InfoHolder I int }
func (Int) WithInfo ¶
func (x Int) WithInfo(info *ObjectInfo) Object
type KVReduce ¶
type KVReduce interface {
// contains filtered or unexported methods
}
func AssertKVReduce ¶
func EnsureKVReduce ¶
type Keyword ¶
type Keyword struct { InfoHolder // contains filtered or unexported fields }
func AssertKeyword ¶
func EnsureKeyword ¶
func MakeKeyword ¶
func (Keyword) WithInfo ¶
func (x Keyword) WithInfo(info *ObjectInfo) Object
type LazySeq ¶
type LazySeq struct { InfoHolder MetaHolder // contains filtered or unexported fields }
func (*LazySeq) IsRealized ¶
func (*LazySeq) WithInfo ¶
func (x *LazySeq) WithInfo(info *ObjectInfo) Object
type LineRuneReader ¶
type LineRuneReader struct {
// contains filtered or unexported fields
}
func NewLineRuneReader ¶
func NewLineRuneReader(rl *readline.Instance) *LineRuneReader
type List ¶
type List struct { InfoHolder MetaHolder // contains filtered or unexported fields }
func NewListFrom ¶
func (*List) Empty ¶
func (list *List) Empty() Collection
func (*List) WithInfo ¶
func (x *List) WithInfo(info *ObjectInfo) Object
type LiteralExpr ¶
type LiteralExpr struct { Position // contains filtered or unexported fields }
func NewLiteralExpr ¶
func NewLiteralExpr(obj Object) *LiteralExpr
func NewSurrogateExpr ¶ added in v0.8.4
func NewSurrogateExpr(obj Object) *LiteralExpr
func (*LiteralExpr) Dump ¶ added in v0.8.2
func (expr *LiteralExpr) Dump(pos bool) Map
func (*LiteralExpr) Eval ¶
func (expr *LiteralExpr) Eval(env *LocalEnv) Object
func (*LiteralExpr) InferType ¶ added in v0.8.2
func (expr *LiteralExpr) InferType() *Type
type MacroCallExpr ¶
type MacroCallExpr struct { Position // contains filtered or unexported fields }
func (*MacroCallExpr) Dump ¶ added in v0.8.2
func (expr *MacroCallExpr) Dump(pos bool) Map
func (*MacroCallExpr) Eval ¶
func (expr *MacroCallExpr) Eval(env *LocalEnv) Object
func (*MacroCallExpr) InferType ¶ added in v0.8.2
func (expr *MacroCallExpr) InferType() *Type
func (*MacroCallExpr) Name ¶
func (expr *MacroCallExpr) Name() string
type Map ¶
type Map interface { Associative Seqable Counted Without(key Object) Map Keys() Seq Vals() Seq Merge(m Map) Map Iter() MapIterator }
func ExtractMap ¶ added in v0.8.9
type MapIterator ¶
type MapSet ¶
type MapSet struct { InfoHolder MetaHolder // contains filtered or unexported fields }
func NewSetFromSeq ¶ added in v0.8.1
func (*MapSet) Empty ¶
func (set *MapSet) Empty() Collection
func (*MapSet) WithInfo ¶
func (x *MapSet) WithInfo(info *ObjectInfo) Object
type MappingSeq ¶
type MappingSeq struct { InfoHolder MetaHolder // contains filtered or unexported fields }
func (*MappingSeq) Cons ¶
func (seq *MappingSeq) Cons(obj Object) Seq
func (*MappingSeq) Equals ¶
func (seq *MappingSeq) Equals(other interface{}) bool
func (*MappingSeq) First ¶
func (seq *MappingSeq) First() Object
func (*MappingSeq) GetType ¶
func (seq *MappingSeq) GetType() *Type
func (*MappingSeq) Hash ¶
func (seq *MappingSeq) Hash() uint32
func (*MappingSeq) IsEmpty ¶
func (seq *MappingSeq) IsEmpty() bool
func (*MappingSeq) Pprint ¶ added in v0.8.8
func (seq *MappingSeq) Pprint(w io.Writer, indent int) int
func (*MappingSeq) Rest ¶
func (seq *MappingSeq) Rest() Seq
func (*MappingSeq) Seq ¶
func (seq *MappingSeq) Seq() Seq
func (*MappingSeq) ToString ¶
func (seq *MappingSeq) ToString(escape bool) string
func (*MappingSeq) WithInfo ¶
func (x *MappingSeq) WithInfo(info *ObjectInfo) Object
func (*MappingSeq) WithMeta ¶
func (seq *MappingSeq) WithMeta(meta Map) Object
type MetaHolder ¶
type MetaHolder struct {
// contains filtered or unexported fields
}
func (MetaHolder) GetMeta ¶
func (m MetaHolder) GetMeta() Map
type Namespace ¶
type Namespace struct { MetaHolder Name Symbol // contains filtered or unexported fields }
func AssertNamespace ¶
func EnsureNamespace ¶
func NewNamespace ¶
func (*Namespace) GetInfo ¶
func (ns *Namespace) GetInfo() *ObjectInfo
func (*Namespace) WithInfo ¶
func (ns *Namespace) WithInfo(info *ObjectInfo) Object
type Nil ¶
type Nil struct { InfoHolder // contains filtered or unexported fields }
func (Nil) Assoc ¶
func (n Nil) Assoc(key, value Object) Associative
func (Nil) Iter ¶
func (n Nil) Iter() MapIterator
func (Nil) WithInfo ¶
func (x Nil) WithInfo(info *ObjectInfo) Object
type NodeIterator ¶
type NodeIterator struct {
// contains filtered or unexported fields
}
func (*NodeIterator) HasNext ¶
func (iter *NodeIterator) HasNext() bool
func (*NodeIterator) Next ¶
func (iter *NodeIterator) Next() *Pair
type NodeSeq ¶
type NodeSeq struct { InfoHolder MetaHolder // contains filtered or unexported fields }
func (*NodeSeq) WithInfo ¶
func (x *NodeSeq) WithInfo(info *ObjectInfo) Object
type Number ¶
type Number interface { Object Int() Int Double() Double BigInt() *big.Int BigFloat() *big.Float Ratio() *big.Rat }
func AssertNumber ¶
func EnsureNumber ¶
func ExtractNumber ¶ added in v0.8.9
type Object ¶
type Object interface { Equality ToString(escape bool) string GetInfo() *ObjectInfo WithInfo(*ObjectInfo) Object GetType() *Type Hash() uint32 }
func DeriveReadObject ¶
func ExtractObject ¶ added in v0.8.0
func MakeReadObject ¶
type ObjectInfo ¶
type ObjectInfo struct {
Position
}
type Ops ¶
type Ops interface { Combine(ops Ops) Ops Add(Number, Number) Number Subtract(Number, Number) Number Multiply(Number, Number) Number Divide(Number, Number) Number IsZero(Number) bool Lt(Number, Number) bool Lte(Number, Number) bool Gt(Number, Number) bool Gte(Number, Number) bool Eq(Number, Number) bool Quotient(Number, Number) Number Rem(Number, Number) Number }
type ParseContext ¶
type ParseContext struct { GlobalEnv *Env // contains filtered or unexported fields }
func (*ParseContext) GetLocalBinding ¶
func (ctx *ParseContext) GetLocalBinding(sym Symbol) *Binding
func (*ParseContext) GetLoopBindings ¶
func (ctx *ParseContext) GetLoopBindings() []Symbol
func (*ParseContext) PopLocalFrame ¶
func (ctx *ParseContext) PopLocalFrame()
func (*ParseContext) PopLoopBindings ¶
func (ctx *ParseContext) PopLoopBindings()
func (*ParseContext) PushEmptyLocalFrame ¶
func (ctx *ParseContext) PushEmptyLocalFrame()
func (*ParseContext) PushLocalFrame ¶
func (ctx *ParseContext) PushLocalFrame(names []Symbol)
func (*ParseContext) PushLoopBindings ¶
func (ctx *ParseContext) PushLoopBindings(bindings []Symbol)
type ParseError ¶
type ParseError struct {
// contains filtered or unexported fields
}
func (*ParseError) Equals ¶
func (err *ParseError) Equals(other interface{}) bool
func (ParseError) Error ¶
func (err ParseError) Error() string
func (*ParseError) GetInfo ¶
func (err *ParseError) GetInfo() *ObjectInfo
func (*ParseError) GetType ¶
func (err *ParseError) GetType() *Type
func (*ParseError) Hash ¶
func (err *ParseError) Hash() uint32
func (*ParseError) ToString ¶
func (err *ParseError) ToString(escape bool) string
func (*ParseError) WithInfo ¶
func (err *ParseError) WithInfo(info *ObjectInfo) Object
type Pending ¶
type Pending interface {
IsRealized() bool
}
func AssertPending ¶
func EnsurePending ¶
type Position ¶
type Position struct {
// contains filtered or unexported fields
}
func GetPosition ¶
type Proc ¶
func (Proc) GetInfo ¶
func (p Proc) GetInfo() *ObjectInfo
func (Proc) WithInfo ¶
func (p Proc) WithInfo(*ObjectInfo) Object
type Ratio ¶
type Ratio struct { InfoHolder // contains filtered or unexported fields }
func AssertRatio ¶
func EnsureRatio ¶
func (*Ratio) WithInfo ¶
func (x *Ratio) WithInfo(info *ObjectInfo) Object
type ReadError ¶
type ReadError struct {
// contains filtered or unexported fields
}
func MakeReadError ¶
type RecurBindings ¶
type RecurBindings []Object
func (RecurBindings) Equals ¶
func (rb RecurBindings) Equals(other interface{}) bool
func (RecurBindings) GetInfo ¶
func (rb RecurBindings) GetInfo() *ObjectInfo
func (RecurBindings) GetType ¶
func (rb RecurBindings) GetType() *Type
func (RecurBindings) Hash ¶
func (rb RecurBindings) Hash() uint32
func (RecurBindings) ToString ¶
func (rb RecurBindings) ToString(escape bool) string
func (RecurBindings) WithInfo ¶
func (x RecurBindings) WithInfo(info *ObjectInfo) Object
type Regex ¶
type Regex struct { InfoHolder R *regexp.Regexp }
func AssertRegex ¶
func EnsureRegex ¶
func (Regex) WithInfo ¶
func (x Regex) WithInfo(info *ObjectInfo) Object
type Reversible ¶
type Reversible interface {
Rseq() Seq
}
func AssertReversible ¶
func AssertReversible(obj Object, msg string) Reversible
func EnsureReversible ¶
func EnsureReversible(args []Object, index int) Reversible
type RuneWindow ¶
type RuneWindow struct {
// contains filtered or unexported fields
}
type Runtime ¶
type Runtime struct {
// contains filtered or unexported fields
}
func (*Runtime) NewArgTypeError ¶ added in v0.8.0
type SeqIterator ¶
type SeqIterator struct {
// contains filtered or unexported fields
}
func (*SeqIterator) HasNext ¶
func (iter *SeqIterator) HasNext() bool
func (*SeqIterator) Next ¶
func (iter *SeqIterator) Next() Object
type Seqable ¶
type Seqable interface {
Seq() Seq
}
func AssertSeqable ¶
func EnsureSeqable ¶
func ExtractSeqable ¶ added in v0.8.0
type Sequential ¶
type Sequential interface {
// contains filtered or unexported methods
}
type SortableSlice ¶
type SortableSlice struct {
// contains filtered or unexported fields
}
func (SortableSlice) Len ¶
func (s SortableSlice) Len() int
func (SortableSlice) Less ¶
func (s SortableSlice) Less(i, j int) bool
func (SortableSlice) Swap ¶
func (s SortableSlice) Swap(i, j int)
type String ¶
type String struct { InfoHolder S string }
func AssertString ¶
func EnsureString ¶
func MakeString ¶
func (String) WithInfo ¶
func (x String) WithInfo(info *ObjectInfo) Object
type StringPool ¶
var STRINGS StringPool = StringPool{}
func (StringPool) Intern ¶
func (p StringPool) Intern(s string) *string
type Symbol ¶
type Symbol struct { InfoHolder MetaHolder // contains filtered or unexported fields }
func AssertSymbol ¶
func EnsureSymbol ¶
func MakeSymbol ¶
func (Symbol) WithInfo ¶
func (x Symbol) WithInfo(info *ObjectInfo) Object
type Type ¶
type Type struct {
// contains filtered or unexported fields
}
func AssertType ¶
func EnsureType ¶
func (*Type) GetInfo ¶
func (t *Type) GetInfo() *ObjectInfo
func (*Type) WithInfo ¶
func (x *Type) WithInfo(info *ObjectInfo) Object
type Types ¶ added in v0.8.1
type Types struct { Associative *Type Callable *Type Collection *Type Comparable *Type Comparator *Type Counted *Type Deref *Type Error *Type Gettable *Type Indexed *Type IOReader *Type KVReduce *Type Map *Type Meta *Type Named *Type Number *Type Pending *Type Ref *Type Reversible *Type Seq *Type Seqable *Type Sequential *Type Set *Type Stack *Type ArrayMap *Type ArrayMapSeq *Type ArrayNodeSeq *Type ArraySeq *Type MapSet *Type Atom *Type BigFloat *Type BigInt *Type Bool *Type Buffer *Type Char *Type ConsSeq *Type Delay *Type Double *Type EvalError *Type ExInfo *Type Fn *Type File *Type BufferedReader *Type HashMap *Type Int *Type Keyword *Type LazySeq *Type List *Type MappingSeq *Type Namespace *Type Nil *Type NodeSeq *Type ParseError *Type Proc *Type Ratio *Type RecurBindings *Type Regex *Type String *Type Symbol *Type Type *Type Var *Type Vector *Type VectorRSeq *Type VectorSeq *Type }
var TYPE Types
type Var ¶
type Var struct { InfoHolder MetaHolder Value Object // contains filtered or unexported fields }
var LINTER_CONFIG *Var
func InternFakeSymbol ¶ added in v0.7.0
func (*Var) WithInfo ¶
func (x *Var) WithInfo(info *ObjectInfo) Object
type VarRefExpr ¶
type VarRefExpr struct { Position // contains filtered or unexported fields }
func (*VarRefExpr) Dump ¶ added in v0.8.2
func (expr *VarRefExpr) Dump(pos bool) Map
func (*VarRefExpr) Eval ¶
func (expr *VarRefExpr) Eval(env *LocalEnv) Object
func (*VarRefExpr) InferType ¶ added in v0.8.2
func (expr *VarRefExpr) InferType() *Type
type Vector ¶
type Vector struct { InfoHolder MetaHolder // contains filtered or unexported fields }
func AssertVector ¶
func EnsureVector ¶
func NewVectorFrom ¶
func NewVectorFromSeq ¶
func (*Vector) Assoc ¶
func (v *Vector) Assoc(key, val Object) Associative
func (*Vector) Empty ¶
func (v *Vector) Empty() Collection
func (*Vector) WithInfo ¶
func (x *Vector) WithInfo(info *ObjectInfo) Object
type VectorExpr ¶
type VectorExpr struct { Position // contains filtered or unexported fields }
func (*VectorExpr) Dump ¶ added in v0.8.2
func (expr *VectorExpr) Dump(pos bool) Map
func (*VectorExpr) Eval ¶
func (expr *VectorExpr) Eval(env *LocalEnv) Object
func (*VectorExpr) InferType ¶ added in v0.8.2
func (expr *VectorExpr) InferType() *Type
type VectorRSeq ¶
type VectorRSeq struct { InfoHolder MetaHolder // contains filtered or unexported fields }
func (*VectorRSeq) Cons ¶
func (vseq *VectorRSeq) Cons(obj Object) Seq
func (*VectorRSeq) Equals ¶
func (vseq *VectorRSeq) Equals(other interface{}) bool
func (*VectorRSeq) First ¶
func (vseq *VectorRSeq) First() Object
func (*VectorRSeq) GetType ¶
func (vseq *VectorRSeq) GetType() *Type
func (*VectorRSeq) Hash ¶
func (vseq *VectorRSeq) Hash() uint32
func (*VectorRSeq) IsEmpty ¶
func (vseq *VectorRSeq) IsEmpty() bool
func (*VectorRSeq) Pprint ¶ added in v0.8.8
func (seq *VectorRSeq) Pprint(w io.Writer, indent int) int
func (*VectorRSeq) Rest ¶
func (vseq *VectorRSeq) Rest() Seq
func (*VectorRSeq) Seq ¶
func (seq *VectorRSeq) Seq() Seq
func (*VectorRSeq) ToString ¶
func (vseq *VectorRSeq) ToString(escape bool) string
func (*VectorRSeq) WithInfo ¶
func (x *VectorRSeq) WithInfo(info *ObjectInfo) Object
func (*VectorRSeq) WithMeta ¶
func (vseq *VectorRSeq) WithMeta(meta Map) Object
type VectorSeq ¶
type VectorSeq struct { InfoHolder MetaHolder // contains filtered or unexported fields }
func (*VectorSeq) WithInfo ¶
func (x *VectorSeq) WithInfo(info *ObjectInfo) Object
Source Files ¶
Click to show internal directories.
Click to hide internal directories.