instance

package
v0.0.0 Latest Latest
Warning

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

Go to latest
Published: Feb 4, 2020 License: MPL-2.0 Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var ArithmeticErrorClass = NewBuiltInClass("<ARITHMETIC-ERROR>", ErrorClass, "OPERATION", "OPERANDS")
View Source
var BasicArrayClass = NewBuiltInClass("<BASIC-ARRAY>", ObjectClass)
View Source
var BasicArrayStarClass = NewBuiltInClass("<BASIC-ARRAY*>", BasicArrayClass)
View Source
var BasicVectorClass = NewBuiltInClass("<BASIC-VECTOR>", BasicArrayClass)
View Source
var BlockTagClass = NewBuiltInClass("<BLOCK-TAG>", EscapeClass, "IRIS.OBJECT")
View Source
var BuiltInClassClass = NewBuiltInClass("<BUILT-IN-CLASS>", ObjectClass)
View Source
var CatchTagClass = NewBuiltInClass("<THROW>", EscapeClass, "IRIS.OBJECT")
View Source
var CharacterClass = NewBuiltInClass("<CHARACTER>", ObjectClass)
View Source
var ConsClass = NewBuiltInClass("<CONS>", ListClass)
View Source
var ContinueClass = NewBuiltInClass("<CONTINUE>", EscapeClass, "IRIS.OBJECT")
View Source
var ControlErrorClass = NewBuiltInClass("<CONTROL-ERROR>", ErrorClass)
View Source
var DivisionByZeroClass = NewBuiltInClass("<DIVISION-BY-ZERO>", ArithmeticErrorClass)
View Source
var DomainErrorClass = NewBuiltInClass("<DOMAIN-ERROR>", ProgramErrorClass, "IRIS.OBJECT", "EXPECTED-CLASS")
View Source
var EndOfStreamClass = NewBuiltInClass("<END-OF-STREAM>", StreamErrorClass)
View Source
var ErrorClass = NewBuiltInClass("<ERROR>", SeriousConditionClass)
View Source
var EscapeClass = NewBuiltInClass("<ESCAPE>", ObjectClass, "IRIS.TAG")

Implementation defined

View Source
var FloatClass = NewBuiltInClass("<FLOAT>", NumberClass)
View Source
var FloatingPointOnderflowClass = NewBuiltInClass("<FLOATING-POINT-OVERFLOW>", ArithmeticErrorClass)
View Source
var FloatingPointUnderflowClass = NewBuiltInClass("<FLOATING-POINT-UNDERFLOW>", ArithmeticErrorClass)
View Source
var FunctionClass = NewBuiltInClass("<FUNCTION>", ObjectClass)
View Source
var GeneralArrayStarClass = NewBuiltInClass("<GENERAL-ARRAY*>", BasicArrayStarClass)
View Source
var GeneralVectorClass = NewBuiltInClass("<GENERAL-VECTOR>", BasicVectorClass)
View Source
var GenericFunctionClass = NewBuiltInClass("<GENERIC-FUNCTION>", FunctionClass)
View Source
var IntegerClass = NewBuiltInClass("<INTEGER>", NumberClass)
View Source
var ListClass = NewBuiltInClass("<LIST>", ObjectClass)
View Source
var Nil = NewNull()
View Source
var NumberClass = NewBuiltInClass("<NUMBER>", ObjectClass)
View Source
var ObjectClass = BuiltInClass{NewSymbol("<OBJECT>"), []ilos.Class{}, []ilos.Instance{}}
View Source
var ParseErrorClass = NewBuiltInClass("<PARSE-ERROR>", ErrorClass, "STRING", "EXPECTED-CLASS")
View Source
var ProgramErrorClass = NewBuiltInClass("<PROGRAM-ERROR>", ErrorClass)
View Source
var SeriousConditionClass = NewBuiltInClass("<SERIOUS-CONDITION>", ObjectClass)
View Source
var SimpleErrorClass = NewBuiltInClass("<SIMPLE-ERROR>", ErrorClass, "FORMAT-STRING", "FORMAT-ARGUMENTS")
View Source
var StandardClassClass = NewBuiltInClass("<STANDARD-CLASS>", ObjectClass)
View Source
var StandardGenericFunctionClass = NewBuiltInClass("<STANDARD-GENERIC-FUNCTION>", GenericFunctionClass)
View Source
var StandardObjectClass = NewBuiltInClass("<STANDARD-OBJECT>", ObjectClass)
View Source
var StorageExhaustedClass = NewBuiltInClass("<STORAGE-EXHAUSTED>", SeriousConditionClass)
View Source
var StreamClass = NewBuiltInClass("<STREAM>", ObjectClass, "STREAM")
View Source
var StreamErrorClass = NewBuiltInClass("<STREAM-ERROR>", ErrorClass)
View Source
var StringClass = NewBuiltInClass("<STRING>", BasicVectorClass)
View Source
var SymbolClass = NewBuiltInClass("<SYMBOL>", ObjectClass)
View Source
var T = NewSymbol("T")
View Source
var TagbodyTagClass = NewBuiltInClass("<TAGBODY-TAG>", EscapeClass)
View Source
var UndefinedEntityClass = NewBuiltInClass("<UNDEFINED-ENTITY>", ProgramErrorClass, "NAME", "NAMESPACE")
View Source
var UndefinedFunctionClass = NewBuiltInClass("<UNDEFINED-FUNCTION>", UndefinedEntityClass)
View Source
var UndefinedVariableClass = NewBuiltInClass("<UNDEFINED-VARIABLE>", UndefinedEntityClass)

Functions

func Create

func InitializeObject

func InitializeObject(e env.Environment, object ilos.Instance, inits ...ilos.Instance) ilos.Instance

func NewArithmeticError

func NewArithmeticError(e env.Environment, operation, operands ilos.Instance) ilos.Instance

func NewArityError

func NewArityError(e env.Environment) ilos.Instance

func NewBlockTag

func NewBlockTag(tag, uid, object ilos.Instance) ilos.Instance

func NewBuiltInClass

func NewBuiltInClass(name string, super ilos.Class, slots ...string) ilos.Class

func NewCatchTag

func NewCatchTag(tag, uid, object ilos.Instance) ilos.Instance

func NewCharacter

func NewCharacter(r rune) ilos.Instance

func NewCons

func NewCons(car, cdr ilos.Instance) ilos.Instance

func NewControlError

func NewControlError(e env.Environment) ilos.Instance

func NewDivisionByZero

func NewDivisionByZero(e env.Environment, operation, operands ilos.Instance) ilos.Instance

func NewDomainError

func NewDomainError(e env.Environment, object ilos.Instance, expectedClass ilos.Class) ilos.Instance

func NewFloat

func NewFloat(i float64) ilos.Instance

func NewFunction

func NewFunction(name ilos.Instance, function interface{}) ilos.Instance

func NewGeneralArrayStar

func NewGeneralArrayStar(vector []*GeneralArrayStar, scalar ilos.Instance) ilos.Instance

func NewGeneralVector

func NewGeneralVector(v []ilos.Instance) ilos.Instance

func NewGenericFunction

func NewGenericFunction(funcSpec, lambdaList, methodCombination ilos.Instance, genericFunctionClass ilos.Class) ilos.Instance

func NewImmutableBinding

func NewImmutableBinding(e env.Environment) ilos.Instance

func NewIndexOutOfRange

func NewIndexOutOfRange(e env.Environment) ilos.Instance

func NewInteger

func NewInteger(i int) ilos.Instance

func NewNull

func NewNull() ilos.Instance

func NewParseError

func NewParseError(e env.Environment, str, expectedClass ilos.Instance) ilos.Instance

func NewSimpleError

func NewSimpleError(e env.Environment, formatString, formatArguments ilos.Instance) ilos.Instance

func NewStandardClass

func NewStandardClass(name ilos.Instance, supers []ilos.Class, slots []ilos.Instance, initforms, initargs map[ilos.Instance]ilos.Instance, metaclass ilos.Class, abstractp ilos.Instance) ilos.Class

func NewStream

func NewStream(r io.Reader, w io.Writer) ilos.Instance

func NewStreamError

func NewStreamError(e env.Environment) ilos.Instance

func NewString

func NewString(s []rune) ilos.Instance

func NewSymbol

func NewSymbol(s string) ilos.Instance

func NewTagbodyTag

func NewTagbodyTag(tag, uid ilos.Instance) ilos.Instance

func NewUndefinedClass

func NewUndefinedClass(e env.Environment, name ilos.Instance) ilos.Instance

func NewUndefinedFunction

func NewUndefinedFunction(e env.Environment, name ilos.Instance) ilos.Instance

func NewUndefinedVariable

func NewUndefinedVariable(e env.Environment, name ilos.Instance) ilos.Instance

Types

type Applicable

type Applicable interface {
	Apply(env.Environment, ...ilos.Instance) (ilos.Instance, ilos.Instance)
}

type BuiltInClass

type BuiltInClass struct {
	// contains filtered or unexported fields
}

func (BuiltInClass) Class

func (BuiltInClass) Class() ilos.Class

func (BuiltInClass) Initarg

func (p BuiltInClass) Initarg(arg ilos.Instance) (ilos.Instance, bool)

func (BuiltInClass) Initform

func (p BuiltInClass) Initform(arg ilos.Instance) (ilos.Instance, bool)

func (BuiltInClass) Slots

func (p BuiltInClass) Slots() []ilos.Instance

func (BuiltInClass) String

func (p BuiltInClass) String() string

func (BuiltInClass) Supers

func (p BuiltInClass) Supers() []ilos.Class

type Character

type Character rune

func (Character) Class

func (Character) Class() ilos.Class

func (Character) String

func (i Character) String() string

type Cons

type Cons struct {
	Car ilos.Instance
	Cdr ilos.Instance
}

func (*Cons) Class

func (*Cons) Class() ilos.Class

func (*Cons) Length

func (i *Cons) Length() int

func (*Cons) Nth

func (i *Cons) Nth(n int) ilos.Instance

func (*Cons) NthCdr

func (i *Cons) NthCdr(n int) ilos.Instance

func (*Cons) SetNth

func (i *Cons) SetNth(obj ilos.Instance, n int)

func (*Cons) Slice

func (i *Cons) Slice() []ilos.Instance

func (*Cons) String

func (i *Cons) String() string

type Float

type Float float64

func (Float) Class

func (Float) Class() ilos.Class

func (Float) String

func (i Float) String() string

type Function

type Function struct {
	// contains filtered or unexported fields
}

func (Function) Apply

func (f Function) Apply(e env.Environment, arguments ...ilos.Instance) (ilos.Instance, ilos.Instance)

func (Function) Class

func (Function) Class() ilos.Class

func (Function) String

func (f Function) String() string

type GeneralArrayStar

type GeneralArrayStar struct {
	Vector []*GeneralArrayStar
	Scalar ilos.Instance
}

func (*GeneralArrayStar) Class

func (*GeneralArrayStar) Class() ilos.Class

func (*GeneralArrayStar) String

func (i *GeneralArrayStar) String() string

type GeneralVector

type GeneralVector []ilos.Instance

func (GeneralVector) Class

func (GeneralVector) Class() ilos.Class

func (GeneralVector) String

func (i GeneralVector) String() string

type GenericFunction

type GenericFunction struct {
	// contains filtered or unexported fields
}

func (*GenericFunction) AddMethod

func (f *GenericFunction) AddMethod(qualifier, lambdaList ilos.Instance, classList []ilos.Class, function ilos.Instance) bool

func (*GenericFunction) Apply

func (f *GenericFunction) Apply(e env.Environment, arguments ...ilos.Instance) (ilos.Instance, ilos.Instance)

func (*GenericFunction) Class

func (f *GenericFunction) Class() ilos.Class

func (*GenericFunction) String

func (f *GenericFunction) String() string

type Instance

type Instance struct {
	// contains filtered or unexported fields
}

func (Instance) Class

func (i Instance) Class() ilos.Class

func (Instance) GetSlotValue

func (i Instance) GetSlotValue(key ilos.Instance, class ilos.Class) (ilos.Instance, bool)

func (Instance) SetSlotValue

func (i Instance) SetSlotValue(key ilos.Instance, value ilos.Instance, class ilos.Class) bool

func (Instance) String

func (i Instance) String() string

type Integer

type Integer int

func (Integer) Class

func (Integer) Class() ilos.Class

func (Integer) String

func (i Integer) String() string

type List

type List interface {
	Slice() []ilos.Instance
	Nth(i int) ilos.Instance
	SetNth(obj ilos.Instance, i int)
	NthCdr(i int) ilos.Instance
	Length() int
}

type Null

type Null struct{}

func (*Null) Class

func (*Null) Class() ilos.Class

func (*Null) Length

func (i *Null) Length() int

func (*Null) Nth

func (i *Null) Nth(n int) ilos.Instance

func (*Null) NthCdr

func (i *Null) NthCdr(n int) ilos.Instance

func (*Null) SetNth

func (i *Null) SetNth(obj ilos.Instance, n int)

func (*Null) Slice

func (*Null) Slice() []ilos.Instance

func (*Null) String

func (*Null) String() string

type StandardClass

type StandardClass struct {
	// contains filtered or unexported fields
}

func (StandardClass) Class

func (p StandardClass) Class() ilos.Class

func (StandardClass) Initarg

func (p StandardClass) Initarg(arg ilos.Instance) (ilos.Instance, bool)

func (StandardClass) Initform

func (p StandardClass) Initform(arg ilos.Instance) (ilos.Instance, bool)

func (StandardClass) Slots

func (p StandardClass) Slots() []ilos.Instance

func (StandardClass) String

func (p StandardClass) String() string

func (StandardClass) Supers

func (p StandardClass) Supers() []ilos.Class

type Stream

type Stream struct {
	Column *int
	Reader *tokenizer.Reader
	Writer io.Writer
}

func (Stream) Class

func (Stream) Class() ilos.Class

func (Stream) Read

func (s Stream) Read(p []byte) (n int, err error)

func (Stream) String

func (Stream) String() string

func (Stream) Write

func (s Stream) Write(p []byte) (n int, err error)

type String

type String []rune

func (String) Class

func (String) Class() ilos.Class

func (String) String

func (i String) String() string

type Symbol

type Symbol string

func (Symbol) Class

func (Symbol) Class() ilos.Class

func (Symbol) String

func (i Symbol) String() string

Jump to

Keyboard shortcuts

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