golisp

package module
v0.0.0-...-387b0d1 Latest Latest
Warning

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

Go to latest
Published: May 20, 2021 License: BSD-3-Clause Imports: 25 Imported by: 3

README

golisp

GoLisp is a simple Lisp language and runtime implemented in Google’s Go programming language. It’s main purpose is integration into a Go application to provide runtime extension and scripting. The core of a basic Lisp is provided, but with limited special forms and primitive functions. More of these will be added as required without having to modify the GoLisp core. Also, a REPL is provided and GoLisp can be used as-is to enter and evaluate code.

It is heavily inspired and influenced by Scheme (MIT/GNU scheme in particular). GoLisp 1.0 is much more in line with Scheme, but it is at it's heart a language for our purposes internally. It's growth and evolution reflect that.

GoLisp evolves along 4 axis:

  • becoming more compatible with MIT/GNU Scheme (GoLisp v1.0 is a huge move forward in this regard)
  • supporting more capabilities of the underlying Go implementation language (e.g. recent work supporting concurrency and channels)
  • our particular needs (e.g. byte array support)
  • useful additions (e.g. frames)

If GoLisp has a form or function that is also in MIT/GNU scheme, we strive to make it work the same way.

As much as possible the internals echo those in MIT/GNU Scheme. For example, the lexical environment structure/handling.

So, while it is intentionally very much like MIT/GNU Scheme, it is not constrained to conform the specification. That said, unless our extensions are used, code will usually be indistinguishable.

A complete language reference and other material is available at http://techblog.steelseries.com/golisp.

A sample application is also available at https://github.com/SteelSeries/golisp-example-app.

GoLisp has the following dependencies:

go get github.com/SteelSeries/set.v0 go get github.com/SteelSeries/bufrr go get gopkg.in/check.v1

Documentation

Overview

sniped from https://github.com/rocaltair/goreadline

Index

Constants

View Source
const (
	NilType = iota
	ConsCellType
	AlistType
	AlistCellType
	IntegerType
	FloatType
	BooleanType
	StringType
	SymbolType
	FunctionType
	MacroType
	PrimitiveType
	BoxedObjectType
	FrameType
	EnvironmentType
	PortType
)
View Source
const (
	TrimLeft  = iota
	TrimBoth  = iota
	TrimRight = iota
)
View Source
const (
	ARGS_ANY = iota
	ARGS_EQ
	ARGS_GTE
	ARGS_RANGE
)
View Source
const (
	READ_LOCK = iota
	WRITE_LOCK
)
View Source
const (
	ILLEGAL = iota
	SYMBOL
	NUMBER
	HEXNUMBER
	BINARYNUMBER
	FLOAT
	STRING
	QUOTE
	BACKQUOTE
	COMMA
	COMMAAT
	LPAREN
	RPAREN
	LBRACKET
	RBRACKET
	LBRACE
	RBRACE
	PERIOD
	TRUE
	FALSE
	COMMENT
	EOF
)

Variables

View Source
var DebugCommandPrefix string = ":"
View Source
var DebugEvalInDebugRepl bool = false
View Source
var DebugOnEntry *set.Set = set.New()
View Source
var DebugOnError bool = false
View Source
var DebugSingleStep bool = false
View Source
var DebugTrace = false
View Source
var EvalDepth int = 0
View Source
var IsInteractive bool = false
View Source
var LispTrace = false
View Source
var ProfileEnabled = false
View Source
var ProfileGUID int64 = 0
View Source
var TopLevelEnvironments environmentsTable = environmentsTable{make(map[string]*SymbolTableFrame, 5), sync.RWMutex{}}

Functions

func AddHistory

func AddHistory(line string)

func AddLog

func AddLog(newLog *log.Logger)

func AlistP

func AlistP(d *Data) bool

func BooleanP

func BooleanP(d *Data) bool

func BooleanValue

func BooleanValue(d *Data) bool

func ClearHistory

func ClearHistory()

func DebugRepl

func DebugRepl(env *SymbolTableFrame)

func DottedPairP

func DottedPairP(d *Data) bool

func EndProfiling

func EndProfiling()

func EnvironmentP

func EnvironmentP(d *Data) bool

func FloatP

func FloatP(d *Data) bool

func FloatValue

func FloatValue(d *Data) float32

func FrameP

func FrameP(d *Data) bool

func FunctionOrPrimitiveP

func FunctionOrPrimitiveP(d *Data) bool

func FunctionP

func FunctionP(d *Data) bool

func InitBuiltins

func InitBuiltins()

func InitEnvironments

func InitEnvironments()

func InitLisp

func InitLisp()

func IntegerP

func IntegerP(d *Data) bool

func IntegerValue

func IntegerValue(d *Data) int64

func IsEqual

func IsEqual(d *Data, o *Data) bool

func Length

func Length(d *Data) int

Function has heavy traffic, try to keep it fast, at least for the list/bytearray cases

func LispToJson

func LispToJson(d *Data) (result interface{})

func LispToJsonString

func LispToJsonString(d *Data) (result string)

func LispWithFramesToJson

func LispWithFramesToJson(d *Data) (result interface{})

func LispWithFramesToJsonString

func LispWithFramesToJsonString(d *Data) (result string)

func ListP

func ListP(d *Data) bool

func LoadHistoryFromFile

func LoadHistoryFromFile(fileName string)

func LogPrint

func LogPrint(a ...interface{})

func LogPrintf

func LogPrintf(format string, a ...interface{})

func LogPrintln

func LogPrintln(a ...interface{})

func MacroP

func MacroP(d *Data) bool

func MakePrimitiveFunction

func MakePrimitiveFunction(name string, argCount string, function func(*Data, *SymbolTableFrame) (*Data, error))

func MakeRestrictedPrimitiveFunction

func MakeRestrictedPrimitiveFunction(name string, argCount string, function func(*Data, *SymbolTableFrame) (*Data, error))

func MakeRestrictedSpecialForm

func MakeRestrictedSpecialForm(name string, argCount string, function func(*Data, *SymbolTableFrame) (*Data, error))

func MakeSpecialForm

func MakeSpecialForm(name string, argCount string, function func(*Data, *SymbolTableFrame) (*Data, error))

func NakedP

func NakedP(d *Data) bool

func NilP

func NilP(d *Data) bool

Function has heavy traffic, try to keep it fast

func NotNilP

func NotNilP(d *Data) bool

func NumberP

func NumberP(d *Data) bool

func ObjectP

func ObjectP(d *Data) bool

func ObjectType

func ObjectType(d *Data) (oType string)

func ObjectValue

func ObjectValue(d *Data) (p unsafe.Pointer)

func PairP

func PairP(d *Data) bool

func PortP

func PortP(d *Data) bool

func PortValue

func PortValue(d *Data) *os.File

func PrimitiveP

func PrimitiveP(d *Data) bool

func PrintString

func PrintString(d *Data) string

func ProcessError

func ProcessError(errorMessage string, env *SymbolTableFrame) error

func ProfileEnter

func ProfileEnter(funcType string, name string, guid int64)

func ProfileExit

func ProfileExit(funcType string, name string, guid int64)

func ReadFile

func ReadFile(filename string) (s string, err error)

func ReadLine

func ReadLine(prompt *string) *string

func RegisterAListPrimitives

func RegisterAListPrimitives()

func RegisterBinaryPrimitives

func RegisterBinaryPrimitives()

func RegisterBytearrayPrimitives

func RegisterBytearrayPrimitives()

func RegisterChannelPrimitives

func RegisterChannelPrimitives()

func RegisterConcurrencyPrimitives

func RegisterConcurrencyPrimitives()

func RegisterDebugPrimitives

func RegisterDebugPrimitives()

func RegisterEnvironmentPrimitives

func RegisterEnvironmentPrimitives()

func RegisterFramePrimitives

func RegisterFramePrimitives()

func RegisterIOPrimitives

func RegisterIOPrimitives()

func RegisterListAccessPrimitives

func RegisterListAccessPrimitives()

func RegisterListFunctionsPrimitives

func RegisterListFunctionsPrimitives()

func RegisterListManipulationPrimitives

func RegisterListManipulationPrimitives()

func RegisterListSetPrimitives

func RegisterListSetPrimitives()

func RegisterMacroPrimitives

func RegisterMacroPrimitives()

func RegisterMathPrimitives

func RegisterMathPrimitives()

func RegisterMutatorPrimitives

func RegisterMutatorPrimitives()

func RegisterRelativePrimitives

func RegisterRelativePrimitives()

func RegisterSpecialFormPrimitives

func RegisterSpecialFormPrimitives()

func RegisterStringPrimitives

func RegisterStringPrimitives()

func RegisterSystemPrimitives

func RegisterSystemPrimitives()

func RegisterTypePredicatePrimitives

func RegisterTypePredicatePrimitives()

func Repl

func Repl()

func StartProfiling

func StartProfiling(fname string)

func String

func String(d *Data) string

func StringP

func StringP(d *Data) bool

func StringValue

func StringValue(d *Data) string

func SymbolP

func SymbolP(d *Data) bool

func TruncateHistoryFile

func TruncateHistoryFile(fileName string, left int)

func TypeName

func TypeName(t uint8) string

func TypeOf

func TypeOf(d *Data) uint8

func WriteHistoryToFile

func WriteHistoryToFile(fileName string)

Types

type ArgRestriction

type ArgRestriction struct {
	Type        int
	Restriction interface{}
}

type Binding

type Binding struct {
	Sym       *Data
	Val       *Data
	Protected bool
}

func BindingWithSymbolAndValue

func BindingWithSymbolAndValue(sym *Data, val *Data) *Binding

func ProtectedBindingWithSymbolAndValue

func ProtectedBindingWithSymbolAndValue(sym *Data, val *Data) *Binding

func (*Binding) Dump

func (self *Binding) Dump()

type BooleanBox

type BooleanBox struct {
	B bool
}

type BoxedObject

type BoxedObject struct {
	ObjType string
	Obj     unsafe.Pointer
}

func BoxedObjectValue

func BoxedObjectValue(d *Data) *BoxedObject

type Channel

type Channel chan *Data

type ConsCell

type ConsCell struct {
	Car *Data
	Cdr *Data
}

func ConsValue

func ConsValue(d *Data) *ConsCell

type Data

type Data struct {
	Type  uint8
	Value unsafe.Pointer
}
var DebugReturnValue *Data = nil
var EofObject *Data = Intern("__EOF__")
var LispFalse *Data = &Data{Type: BooleanType, Value: unsafe.Pointer(&b_false)}
var LispTrue *Data = &Data{Type: BooleanType, Value: unsafe.Pointer(&b_true)}

func AbandonImpl

func AbandonImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func AbsImpl

func AbsImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func Acons

func Acons(car *Data, cdr *Data, alist *Data) *Data

func AconsImpl

func AconsImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func AddDebugOnEntryImpl

func AddDebugOnEntryImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func AddImpl

func AddImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func Alist

func Alist(d *Data) *Data

func AlistImpl

func AlistImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func AnyImpl

func AnyImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func Append

func Append(l *Data, value *Data) *Data

func AppendBang

func AppendBang(l *Data, value *Data) *Data

func AppendBangImpl

func AppendBangImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func AppendBangList

func AppendBangList(l *Data, otherList *Data) *Data

func AppendBytesBangImpl

func AppendBytesBangImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func AppendBytesImpl

func AppendBytesImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func AppendImpl

func AppendImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func AppendList

func AppendList(l *Data, otherList *Data) *Data

func Apply

func Apply(function *Data, args *Data, env *SymbolTableFrame) (result *Data, err error)

func ApplyImpl

func ApplyImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func ApplySlotImpl

func ApplySlotImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func ApplySlotSuperImpl

func ApplySlotSuperImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func ApplyWithoutEval

func ApplyWithoutEval(function *Data, args *Data, env *SymbolTableFrame) (result *Data, err error)

func ArrayToList

func ArrayToList(sexprs []*Data) *Data

func ArrayToListWithTail

func ArrayToListWithTail(sexprs []*Data, tail *Data) *Data

func Assoc

func Assoc(key *Data, alist *Data) (result *Data, err error)

func AssocImpl

func AssocImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func AtomicAddImpl

func AtomicAddImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func AtomicCompareAndSwapImpl

func AtomicCompareAndSwapImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func AtomicImpl

func AtomicImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func AtomicLoadImpl

func AtomicLoadImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func AtomicStoreImpl

func AtomicStoreImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func AtomicSwapImpl

func AtomicSwapImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func BeginImpl

func BeginImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func BinaryAndImpl

func BinaryAndImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func BinaryNotImpl

func BinaryNotImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func BinaryOrImpl

func BinaryOrImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func BitsToFloatImpl

func BitsToFloatImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func BooleanAndImpl

func BooleanAndImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func BooleanNotImpl

func BooleanNotImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func BooleanOrImpl

func BooleanOrImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func BooleanWithValue

func BooleanWithValue(b bool) *Data

func BytesToListImpl

func BytesToListImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func CaaaarImpl

func CaaaarImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func CaaadrImpl

func CaaadrImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func Caaar

func Caaar(d *Data) *Data

func CaaarImpl

func CaaarImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func CaadarImpl

func CaadarImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func CaaddrImpl

func CaaddrImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func Caadr

func Caadr(d *Data) *Data

func CaadrImpl

func CaadrImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func Caar

func Caar(d *Data) *Data

func CaarImpl

func CaarImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func CadaarImpl

func CadaarImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func CadadrImpl

func CadadrImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func Cadar

func Cadar(d *Data) *Data

func CadarImpl

func CadarImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func CaddarImpl

func CaddarImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func CadddrImpl

func CadddrImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func Caddr

func Caddr(d *Data) *Data

func CaddrImpl

func CaddrImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func Cadr

func Cadr(d *Data) *Data

func CadrImpl

func CadrImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func Car

func Car(d *Data) *Data

Function has heavy traffic, try to keep it fast

func CarImpl

func CarImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func CaseImpl

func CaseImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func CdaaarImpl

func CdaaarImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func CdaadrImpl

func CdaadrImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func Cdaar

func Cdaar(d *Data) *Data

func CdaarImpl

func CdaarImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func CdadarImpl

func CdadarImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func CdaddrImpl

func CdaddrImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func Cdadr

func Cdadr(d *Data) *Data

func CdadrImpl

func CdadrImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func Cdar

func Cdar(d *Data) *Data

func CdarImpl

func CdarImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func CddaarImpl

func CddaarImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func CddadrImpl

func CddadrImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func Cddar

func Cddar(d *Data) *Data

func CddarImpl

func CddarImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func CdddarImpl

func CdddarImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func CddddrImpl

func CddddrImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func Cdddr

func Cdddr(d *Data) *Data

func CdddrImpl

func CdddrImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func Cddr

func Cddr(d *Data) *Data

func CddrImpl

func CddrImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func Cdr

func Cdr(d *Data) *Data

Function has heavy traffic, try to keep it fast

func CdrImpl

func CdrImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func CeilingImpl

func CeilingImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func ChainImpl

func ChainImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func ChannelReadImpl

func ChannelReadImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func ChannelTryReadImpl

func ChannelTryReadImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func ChannelTryWriteImpl

func ChannelTryWriteImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func ChannelWriteImpl

func ChannelWriteImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func CloneImpl

func CloneImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func CloseChannelImpl

func CloseChannelImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func ClosePortImpl

func ClosePortImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func ComplementImpl

func ComplementImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func CondImpl

func CondImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func Cons

func Cons(car *Data, cdr *Data) *Data

func ConsImpl

func ConsImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func ConsStarImpl

func ConsStarImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func Copy

func Copy(d *Data) *Data

func CopyImpl

func CopyImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func DebugImpl

func DebugImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func DebugOnEntryImpl

func DebugOnEntryImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func DebugOnErrorImpl

func DebugOnErrorImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func DebugTraceImpl

func DebugTraceImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func DecrementImpl

func DecrementImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func DefineImpl

func DefineImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func DefinitionOfImpl

func DefinitionOfImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func DefmacroImpl

func DefmacroImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func Dissoc

func Dissoc(key *Data, alist *Data) (result *Data, err error)

func DissocImpl

func DissocImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func DoImpl

func DoImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func DropImpl

func DropImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func DumpSymbolTableImpl

func DumpSymbolTableImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func Eighth

func Eighth(d *Data) *Data

func EighthImpl

func EighthImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func EmptyCons

func EmptyCons() *Data

func EnvironmentAssignBangImpl

func EnvironmentAssignBangImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func EnvironmentAssignablePImpl

func EnvironmentAssignablePImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func EnvironmentAssignedPImpl

func EnvironmentAssignedPImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func EnvironmentBindingsImpl

func EnvironmentBindingsImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func EnvironmentBoundNamesImpl

func EnvironmentBoundNamesImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func EnvironmentBoundPImpl

func EnvironmentBoundPImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func EnvironmentDefinablePImpl

func EnvironmentDefinablePImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func EnvironmentDefineImpl

func EnvironmentDefineImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func EnvironmentLookupImpl

func EnvironmentLookupImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func EnvironmentLookupMacroImpl

func EnvironmentLookupMacroImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func EnvironmentMacroNamesImpl

func EnvironmentMacroNamesImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func EnvironmentPImpl

func EnvironmentPImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func EnvironmentParentImpl

func EnvironmentParentImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func EnvironmentParentPImpl

func EnvironmentParentPImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func EnvironmentReferenceTypeImpl

func EnvironmentReferenceTypeImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func EnvironmentWithValue

func EnvironmentWithValue(e *SymbolTableFrame) *Data

func EofObjectImpl

func EofObjectImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func EqualToImpl

func EqualToImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func ErrorImpl

func ErrorImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func Eval

func Eval(d *Data, env *SymbolTableFrame) (result *Data, err error)

func EvalImpl

func EvalImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func EvenImpl

func EvenImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func EveryImpl

func EveryImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func ExecImpl

func ExecImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func ExpandImpl

func ExpandImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func ExtractByteImpl

func ExtractByteImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func ExtractBytesImpl

func ExtractBytesImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func Fifth

func Fifth(d *Data) *Data

func FifthImpl

func FifthImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func FilterImpl

func FilterImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func FindImpl

func FindImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func FindTailImpl

func FindTailImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func FindTopLevelEnvironmentImpl

func FindTopLevelEnvironmentImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func First

func First(d *Data) *Data

func FirstImpl

func FirstImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func Flatten

func Flatten(d *Data) (result *Data, err error)

func FlattenImpl

func FlattenImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func FloatToBitsImpl

func FloatToBitsImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func FloatWithValue

func FloatWithValue(n float32) *Data

func FloorImpl

func FloorImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func FoldLeftImpl

func FoldLeftImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func FoldRightImpl

func FoldRightImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func ForEachImpl

func ForEachImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func ForkImpl

func ForkImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func FormatImpl

func FormatImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func Fourth

func Fourth(d *Data) *Data

func FourthImpl

func FourthImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func FrameKeysImpl

func FrameKeysImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func FrameValuesImpl

func FrameValuesImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func FrameWithValue

func FrameWithValue(m *FrameMap) *Data

func FunctionWithNameParamsBodyAndParent

func FunctionWithNameParamsBodyAndParent(name string, params *Data, body *Data, parentEnv *SymbolTableFrame) *Data

func GeneralCarCdrImpl

func GeneralCarCdrImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func GensymImpl

func GensymImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func GensymNakedImpl

func GensymNakedImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func GetSlotImpl

func GetSlotImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func GetSlotOrNilImpl

func GetSlotOrNilImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func GlobalEvalImpl

func GlobalEvalImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func GreaterThanImpl

func GreaterThanImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func GreaterThanOrEqualToImpl

func GreaterThanOrEqualToImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func HasSlotImpl

func HasSlotImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func IfImpl

func IfImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func IncrementImpl

func IncrementImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func IntegerWithValue

func IntegerWithValue(n int64) *Data

func Intern

func Intern(name string) (sym *Data)

func InternImpl

func InternImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func InternalMakeList

func InternalMakeList(c ...*Data) *Data

func IntersectionImpl

func IntersectionImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func IntervalImpl

func IntervalImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func IsAlistImpl

func IsAlistImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func IsAtomImpl

func IsAtomImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func IsBooleanImpl

func IsBooleanImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func IsByteArrayImpl

func IsByteArrayImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func IsFloatImpl

func IsFloatImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func IsFrameImpl

func IsFrameImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func IsFunctionImpl

func IsFunctionImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func IsInfImpl

func IsInfImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func IsIntegerImpl

func IsIntegerImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func IsMacroImpl

func IsMacroImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func IsNaNImpl

func IsNaNImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func IsNumberImpl

func IsNumberImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func IsPairImpl

func IsPairImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func IsPortImpl

func IsPortImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func IsStringImpl

func IsStringImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func IsSymbolImpl

func IsSymbolImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func JoinImpl

func JoinImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func JsonStringToLisp

func JsonStringToLisp(jsonData string) (result *Data)

func JsonStringToLispWithFrames

func JsonStringToLispWithFrames(jsonData string) (result *Data)

func JsonToLisp

func JsonToLisp(json interface{}) (result *Data)

func JsonToLispImpl

func JsonToLispImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func JsonToLispWithFrames

func JsonToLispWithFrames(data interface{}) *Data

func LambdaImpl

func LambdaImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func LastPairImpl

func LastPairImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func LeftShiftImpl

func LeftShiftImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func LessThanImpl

func LessThanImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func LessThanOrEqualToImpl

func LessThanOrEqualToImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func LetCommon

func LetCommon(args *Data, env *SymbolTableFrame, star bool, rec bool) (result *Data, err error)

func LetImpl

func LetImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func LetRecImpl

func LetRecImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func LetStarImpl

func LetStarImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func LispToJsonImpl

func LispToJsonImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func LispTraceImpl

func LispTraceImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func ListDirectoryImpl

func ListDirectoryImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func ListHeadImpl

func ListHeadImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func ListImpl

func ListImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func ListLengthImpl

func ListLengthImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func ListRefImpl

func ListRefImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func ListTailImpl

func ListTailImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func ListToBytesImpl

func ListToBytesImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func LoadFileImpl

func LoadFileImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func MacroWithNameParamsBodyAndParent

func MacroWithNameParamsBodyAndParent(name string, params *Data, body *Data, parentEnv *SymbolTableFrame) *Data

func MakeChannelImpl

func MakeChannelImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func MakeFrameImpl

func MakeFrameImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func MakeListImpl

func MakeListImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func MakeStringImpl

func MakeStringImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func MakeTopLevelEnvironmentImpl

func MakeTopLevelEnvironmentImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func MapImpl

func MapImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func MaxImpl

func MaxImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func MemqImpl

func MemqImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func MillisImpl

func MillisImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func MinImpl

func MinImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func MultiplyImpl

func MultiplyImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func NakedSymbolFrom

func NakedSymbolFrom(d *Data) *Data

func NakedSymbolWithName

func NakedSymbolWithName(s string) *Data

func NamedLambdaImpl

func NamedLambdaImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func NegativeImpl

func NegativeImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func NewlineImpl

func NewlineImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func NilPImpl

func NilPImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func Ninth

func Ninth(d *Data) *Data

func NinthImpl

func NinthImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func NotEqualImpl

func NotEqualImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func NotNilPImpl

func NotNilPImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func Nth

func Nth(d *Data, n int) *Data

func NthImpl

func NthImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func NumberToStringImpl

func NumberToStringImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func ObjectWithTypeAndValue

func ObjectWithTypeAndValue(typeName string, o unsafe.Pointer) *Data

func OddImpl

func OddImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func OnErrorImpl

func OnErrorImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func OpenInputFileImpl

func OpenInputFileImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func OpenOutputFileImpl

func OpenOutputFileImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func PairlisImpl

func PairlisImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func PanicImpl

func PanicImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func Parse

func Parse(src string) (sexpr *Data, err error)

func ParseAll

func ParseAll(src string) (result []*Data, err error)

func ParseAndEval

func ParseAndEval(src string) (result *Data, err error)

func ParseAndEvalAll

func ParseAndEvalAll(src string) (result *Data, err error)

func ParseAndEvalAllInEnvironment

func ParseAndEvalAllInEnvironment(src string, env *SymbolTableFrame) (result *Data, err error)

func ParseAndEvalInEnvironment

func ParseAndEvalInEnvironment(src string, env *SymbolTableFrame) (result *Data, err error)

func ParseImpl

func ParseImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func ParseObjectFromFileInEnv

func ParseObjectFromFileInEnv(port *os.File, env *SymbolTableFrame) (result *Data, err error)

func PartitionImpl

func PartitionImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func PortWithValue

func PortWithValue(e *os.File) *Data

func PositiveImpl

func PositiveImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func PowImpl

func PowImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func PrimitiveWithNameAndFunc

func PrimitiveWithNameAndFunc(name string, f *PrimitiveFunction) *Data

func ProcSleepImpl

func ProcSleepImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func ProcedureEnvironmentImpl

func ProcedureEnvironmentImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func ProcessFile

func ProcessFile(filename string) (result *Data, err error)

func ProcessFileInEnvironment

func ProcessFileInEnvironment(filename string, env *SymbolTableFrame) (result *Data, err error)

func ProfileImpl

func ProfileImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func QuasiquoteImpl

func QuasiquoteImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func QuitImpl

func QuitImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func QuoteAll

func QuoteAll(d *Data) (result *Data)

func QuoteImpl

func QuoteImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func QuoteIt

func QuoteIt(value *Data) (result *Data)

func QuotientImpl

func QuotientImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func RandomByteImpl

func RandomByteImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

Not tested since it just wraps rand.Int()

func RassocImpl

func RassocImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func ReadImpl

func ReadImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func RecursiveFlatten

func RecursiveFlatten(d *Data) (result *Data, err error)

func RecursiveFlattenImpl

func RecursiveFlattenImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func ReduceLeftImpl

func ReduceLeftImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func ReduceRightImpl

func ReduceRightImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func RemainderImpl

func RemainderImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func RemoveDebugOnEntryImpl

func RemoveDebugOnEntryImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func RemoveFromListBang

func RemoveFromListBang(l *Data, item *Data) (result *Data)

func RemoveImpl

func RemoveImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func RemoveSlotImpl

func RemoveSlotImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func ReplaceByteBangImpl

func ReplaceByteBangImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func ReplaceByteImpl

func ReplaceByteImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func ResetTimeoutImpl

func ResetTimeoutImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func RestrictEnvironmentImpl

func RestrictEnvironmentImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func Reverse

func Reverse(d *Data) (result *Data)

func ReverseImpl

func ReverseImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func RightShiftImpl

func RightShiftImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func ScheduleImpl

func ScheduleImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func Second

func Second(d *Data) *Data

func SecondImpl

func SecondImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func SendImpl

func SendImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func SendSuperImpl

func SendSuperImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func SetCarImpl

func SetCarImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func SetCdrImpl

func SetCdrImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func SetNth

func SetNth(list *Data, index int, value *Data) *Data

func SetNthImpl

func SetNthImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func SetSlotImpl

func SetSlotImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func SetStringValue

func SetStringValue(d *Data, s string) *Data

func SetVarImpl

func SetVarImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func Seventh

func Seventh(d *Data) *Data

func SeventhImpl

func SeventhImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func SignImpl

func SignImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func Sixth

func Sixth(d *Data) *Data

func SixthImpl

func SixthImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func SleepImpl

func SleepImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func SortImpl

func SortImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func StringCapitalizeBangImpl

func StringCapitalizeBangImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func StringCapitalizeImpl

func StringCapitalizeImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func StringDowncaseBangImpl

func StringDowncaseBangImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func StringDowncaseImpl

func StringDowncaseImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func StringEqualCiImpl

func StringEqualCiImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func StringEqualImpl

func StringEqualImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func StringGreaterThanCiImpl

func StringGreaterThanCiImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func StringGreaterThanEqualCiImpl

func StringGreaterThanEqualCiImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func StringGreaterThanEqualImpl

func StringGreaterThanEqualImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func StringGreaterThanImpl

func StringGreaterThanImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func StringJoinImpl

func StringJoinImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func StringLengthImpl

func StringLengthImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func StringLessThanCiImpl

func StringLessThanCiImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func StringLessThanEqualCiImpl

func StringLessThanEqualCiImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func StringLessThanEqualImpl

func StringLessThanEqualImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func StringLessThanImpl

func StringLessThanImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func StringNullImpl

func StringNullImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func StringPrefixpImpl

func StringPrefixpImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func StringSplitImpl

func StringSplitImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func StringSuffixpImpl

func StringSuffixpImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func StringToNumberImpl

func StringToNumberImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func StringTrimImpl

func StringTrimImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func StringTrimLeftImpl

func StringTrimLeftImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func StringTrimRightImpl

func StringTrimRightImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func StringUpcaseBangImpl

func StringUpcaseBangImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func StringUpcaseImpl

func StringUpcaseImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func StringWithValue

func StringWithValue(s string) *Data

func SublistImpl

func SublistImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func SubstringImpl

func SubstringImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func SubstringpImpl

func SubstringpImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func SubtractImpl

func SubtractImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func SymbolWithName

func SymbolWithName(s string) *Data

func SystemGlobalEnvironmentImpl

func SystemGlobalEnvironmentImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func TakeImpl

func TakeImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func TapImpl

func TapImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func Tenth

func Tenth(d *Data) *Data

func TenthImpl

func TenthImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func TheEnvironmentImpl

func TheEnvironmentImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func Third

func Third(d *Data) *Data

func ThirdImpl

func ThirdImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func TimeImpl

func TimeImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func ToArray

func ToArray(list *Data) []*Data

func ToFloatImpl

func ToFloatImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func ToIntImpl

func ToIntImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func TransformJson

func TransformJson(xform *Data, jsonNode *Data, parentNode *Data) (xformedJson *Data, err error)

func UnionImpl

func UnionImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func UnlessImpl

func UnlessImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func UnquoteImpl

func UnquoteImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func UnquoteSplicingImpl

func UnquoteSplicingImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func WakeImpl

func WakeImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func WalkList

func WalkList(d *Data, path string) *Data

func WhenImpl

func WhenImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func WriteBytesImpl

func WriteBytesImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func WriteImpl

func WriteImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func WriteLineImpl

func WriteLineImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func WriteLogImpl

func WriteLogImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func WriteStringImpl

func WriteStringImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

func ZeroImpl

func ZeroImpl(args *Data, env *SymbolTableFrame) (result *Data, err error)

type FrameMap

type FrameMap struct {
	Data  FrameMapData
	Mutex sync.RWMutex
}

func FrameValue

func FrameValue(d *Data) *FrameMap

func (*FrameMap) Clone

func (self *FrameMap) Clone() *FrameMap

func (*FrameMap) Get

func (self *FrameMap) Get(key string) (ret *Data)

func (*FrameMap) HasSlot

func (self *FrameMap) HasSlot(key string) (ret bool)

func (*FrameMap) Keys

func (self *FrameMap) Keys() []*Data

func (*FrameMap) Parents

func (self *FrameMap) Parents() []*FrameMap

func (*FrameMap) Remove

func (self *FrameMap) Remove(key string) bool

func (*FrameMap) Set

func (self *FrameMap) Set(key string, value *Data) *Data

func (*FrameMap) Values

func (self *FrameMap) Values() []*Data

type FrameMapData

type FrameMapData map[string]*Data

type Function

type Function struct {
	Name             string
	Params           *Data
	VarArgs          bool
	RequiredArgCount int
	Body             *Data
	Env              *SymbolTableFrame
	DebugOnEntry     bool
	SlotFunction     int32
	ParentProcess    *Process
}

func FunctionValue

func FunctionValue(d *Data) *Function

func MakeFunction

func MakeFunction(name string, params *Data, body *Data, parentEnv *SymbolTableFrame) *Function

func (*Function) Apply

func (self *Function) Apply(args *Data, argEnv *SymbolTableFrame) (result *Data, err error)

func (*Function) ApplyOveriddingEnvironment

func (self *Function) ApplyOveriddingEnvironment(args *Data, argEnv *SymbolTableFrame) (result *Data, err error)

func (*Function) ApplyWithFrame

func (self *Function) ApplyWithFrame(args *Data, argEnv *SymbolTableFrame, frame *FrameMap) (result *Data, err error)

func (*Function) ApplyWithoutEval

func (self *Function) ApplyWithoutEval(args *Data, argEnv *SymbolTableFrame) (result *Data, err error)

func (*Function) ApplyWithoutEvalWithFrame

func (self *Function) ApplyWithoutEvalWithFrame(args *Data, argEnv *SymbolTableFrame, frame *FrameMap) (result *Data, err error)

func (*Function) String

func (self *Function) String() string

type Macro

type Macro struct {
	Name             string
	Params           *Data
	VarArgs          bool
	RequiredArgCount int
	Body             *Data
	Env              *SymbolTableFrame
}

func MacroValue

func MacroValue(d *Data) *Macro

func MakeMacro

func MakeMacro(name string, params *Data, body *Data, parentEnv *SymbolTableFrame) *Macro

func (*Macro) Apply

func (self *Macro) Apply(args *Data, argEnv *SymbolTableFrame) (result *Data, err error)

func (*Macro) ApplyWithoutEval

func (self *Macro) ApplyWithoutEval(args *Data, argEnv *SymbolTableFrame) (result *Data, err error)

func (*Macro) Expand

func (self *Macro) Expand(args *Data, argEnv *SymbolTableFrame) (result *Data, err error)

func (*Macro) String

func (self *Macro) String() string

type PrimitiveFunction

type PrimitiveFunction struct {
	Name            string
	Special         bool
	ArgRestrictions []ArgRestriction
	ArgTypes        []uint32
	Body            func(d *Data, env *SymbolTableFrame) (*Data, error)
	IsRestricted    bool
}

func PrimitiveValue

func PrimitiveValue(d *Data) *PrimitiveFunction

func (*PrimitiveFunction) Apply

func (self *PrimitiveFunction) Apply(args *Data, env *SymbolTableFrame) (result *Data, err error)

func (*PrimitiveFunction) ApplyWithoutEval

func (self *PrimitiveFunction) ApplyWithoutEval(args *Data, env *SymbolTableFrame) (result *Data, err error)

func (*PrimitiveFunction) String

func (self *PrimitiveFunction) String() string

type Process

type Process struct {
	Env           *SymbolTableFrame
	Code          *Data
	Wake          chan empty
	Abort         chan empty
	Restart       chan empty
	ReturnValue   chan *Data
	Joined        int32
	ScheduleTimer *time.Timer
}

type RangeRestriction

type RangeRestriction struct {
	Hi int
	Lo int
}

type SymbolTableFrame

type SymbolTableFrame struct {
	Name         string
	Parent       *SymbolTableFrame
	Previous     *SymbolTableFrame
	Frame        *FrameMap
	Bindings     map[string]*Binding
	Mutex        sync.RWMutex
	CurrentCode  *list.List
	IsRestricted bool
}
var DebugCurrentFrame *SymbolTableFrame = nil
var DebugErrorEnv *SymbolTableFrame = nil
var Global *SymbolTableFrame

func EnvironmentValue

func EnvironmentValue(d *Data) *SymbolTableFrame

func NewSymbolTableFrameBelow

func NewSymbolTableFrameBelow(p *SymbolTableFrame, name string) *SymbolTableFrame

func NewSymbolTableFrameBelowWithFrame

func NewSymbolTableFrameBelowWithFrame(p *SymbolTableFrame, f *FrameMap, name string) *SymbolTableFrame

func (*SymbolTableFrame) BindLocallyTo

func (self *SymbolTableFrame) BindLocallyTo(symbol *Data, value *Data) (*Data, error)

func (*SymbolTableFrame) BindTo

func (self *SymbolTableFrame) BindTo(symbol *Data, value *Data) (*Data, error)

func (*SymbolTableFrame) BindToProtected

func (self *SymbolTableFrame) BindToProtected(symbol *Data, value *Data) *Data

func (*SymbolTableFrame) BindingNamed

func (self *SymbolTableFrame) BindingNamed(name string) (b *Binding, present bool)

func (*SymbolTableFrame) CurrentCodeString

func (self *SymbolTableFrame) CurrentCodeString() string

func (*SymbolTableFrame) DeleteBinding

func (self *SymbolTableFrame) DeleteBinding(name string)

func (*SymbolTableFrame) Depth

func (self *SymbolTableFrame) Depth() int

func (*SymbolTableFrame) Dump

func (self *SymbolTableFrame) Dump()

func (*SymbolTableFrame) DumpHeader

func (self *SymbolTableFrame) DumpHeader()

func (*SymbolTableFrame) DumpHeaders

func (self *SymbolTableFrame) DumpHeaders()

func (*SymbolTableFrame) DumpSingleFrame

func (self *SymbolTableFrame) DumpSingleFrame(frameNumber int)

func (*SymbolTableFrame) FindBindingFor

func (self *SymbolTableFrame) FindBindingFor(symbol *Data) (binding *Binding, found bool)

func (*SymbolTableFrame) HasFrame

func (self *SymbolTableFrame) HasFrame() bool

func (*SymbolTableFrame) InternalDump

func (self *SymbolTableFrame) InternalDump(frameNumber int)

func (*SymbolTableFrame) InternalDumpHeaders

func (self *SymbolTableFrame) InternalDumpHeaders(frameNumber int)

func (*SymbolTableFrame) SetBindingAt

func (self *SymbolTableFrame) SetBindingAt(name string, b *Binding)

func (*SymbolTableFrame) SetTo

func (self *SymbolTableFrame) SetTo(symbol *Data, value *Data) (result *Data, err error)

func (*SymbolTableFrame) ValueOf

func (self *SymbolTableFrame) ValueOf(symbol *Data) *Data

func (*SymbolTableFrame) ValueOfWithFunctionSlotCheck

func (self *SymbolTableFrame) ValueOfWithFunctionSlotCheck(symbol *Data, needFunction bool) *Data

type Tokenizer

type Tokenizer struct {
	LookaheadToken int
	LookaheadLit   string
	Source         *bufrr.Reader
	CurrentCh      rune
	NextCh         rune
	Eof            bool
	AlmostEof      bool
}

func NewTokenizer

func NewTokenizer(scanner *bufrr.Reader) *Tokenizer

func NewTokenizerFromFile

func NewTokenizerFromFile(src *os.File) *Tokenizer

func NewTokenizerFromString

func NewTokenizerFromString(src string) *Tokenizer

func (*Tokenizer) Advance

func (self *Tokenizer) Advance()

func (*Tokenizer) ConsumeToken

func (self *Tokenizer) ConsumeToken()

func (*Tokenizer) NextToken

func (self *Tokenizer) NextToken() (token int, lit string)

Directories

Path Synopsis
This package impliments a basic LISP interpretor for embedding in a go program for scripting.
This package impliments a basic LISP interpretor for embedding in a go program for scripting.

Jump to

Keyboard shortcuts

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