droscheme

package module
v2.0.0-...-06a724b Latest Latest
Warning

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

Go to latest
Published: Apr 30, 2023 License: GPL-3.0, LGPL-3.0 Imports: 17 Imported by: 0

README

Droscheme - a Scheme implementation.

The goals of Droscheme are to provide a complete numerical tower,
a complete I/O port system including binary and textual ports,
and to experiment with nonstandard numbers and ports.

Documentation

Overview

* Droscheme - a Scheme implementation * Copyright © 2012 Andrew Robbins, Daniel Connelly * * This program is free software: it is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or * FITNESS FOR A PARTICULAR PURPOSE. You can redistribute it and/or modify it under the * terms of the GNU Lesser General Public License (LGPLv3): <http://www.gnu.org/licenses/>.

* Droscheme - a Scheme implementation * Copyright © 2012 Andrew Robbins, Daniel Connelly * * This program is free software: it is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or * FITNESS FOR A PARTICULAR PURPOSE. You can redistribute it and/or modify it under the * terms of the GNU Lesser General Public License (LGPLv3): <http://www.gnu.org/licenses/>.

* Droscheme - a Scheme implementation * Copyright © 2012 Andrew Robbins, Daniel Connelly * * This program is free software: it is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or * FITNESS FOR A PARTICULAR PURPOSE. You can redistribute it and/or modify it under the * terms of the GNU Lesser General Public License (LGPLv3): <http://www.gnu.org/licenses/>.

* Droscheme - a Scheme implementation * Copyright © 2012 Andrew Robbins, Daniel Connelly * * This program is free software: it is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or * FITNESS FOR A PARTICULAR PURPOSE. You can redistribute it and/or modify it under the * terms of the GNU Lesser General Public License (LGPLv3): <http://www.gnu.org/licenses/>.

* Droscheme - a Scheme implementation * Copyright © 2012 Andrew Robbins, Daniel Connelly * * This program is free software: it is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or * FITNESS FOR A PARTICULAR PURPOSE. You can redistribute it and/or modify it under the * terms of the GNU Lesser General Public License (LGPLv3): <http://www.gnu.org/licenses/>.

* Droscheme - a Scheme implementation * Copyright © 2012 Andrew Robbins, Daniel Connelly * * This program is free software: it is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or * FITNESS FOR A PARTICULAR PURPOSE. You can redistribute it and/or modify it under the * terms of the GNU Lesser General Public License (LGPLv3): <http://www.gnu.org/licenses/>.

* Droscheme - a Scheme implementation * Copyright © 2012 Andrew Robbins, Daniel Connelly * * This program is free software: it is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or * FITNESS FOR A PARTICULAR PURPOSE. You can redistribute it and/or modify it under the * terms of the GNU Lesser General Public License (LGPLv3): <http://www.gnu.org/licenses/>.

* Droscheme - a Scheme implementation * Copyright © 2012 Andrew Robbins, Daniel Connelly * * This program is free software: it is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or * FITNESS FOR A PARTICULAR PURPOSE. You can redistribute it and/or modify it under the * terms of the GNU Lesser General Public License (LGPLv3): <http://www.gnu.org/licenses/>.

Index

Constants

View Source
const (
	TypeCodeAny     = iota
	TypeCodeType    // go:SType
	TypeCodeNull    // go:SNull     s:null?       -- Evaler interface
	TypeCodePair    // go:SPair     s:pair?       -- Evaler interface
	TypeCodeChar    // go:SChar     s:char?
	TypeCodeBool    // go:SBool     s:boolean?
	TypeCodeProc    // go:SProc     s:procedure?  -- Applier interface
	TypeCodeBinary  // go:SBinary   s:bytevector? -- Seq interface
	TypeCodeNumber  // go:Num       s:number?     -- Num interface
	TypeCodePort    // go:Port      s:port?       -- Port interface
	TypeCodeString  // go:SString   s:string?     -- Seq interface
	TypeCodeSymbol  // go:SSymbol   s:symbol?     -- Evaler interface
	TypeCodeVector  // go:SVector   s:vector?     -- Seq interface
	TypeCodeTable   // go:STable    s:hashtable?
	TypeCodeRecord  // go:Record                  -- interface
	TypeCodeLibrary //
	TypeCodeValues  // multiple return values
	TypeCodeSyntax  //                            -- Transformer interface
	TypeCodeEnvSpec
	TypeCodeError
	TypeCodeLabel
	TypeCodeVoid

	TypeCodeMax // maximum
)
View Source
const (
	PortTypeCodeByte      = iota
	PortTypeCodeByteIn    // binary intput port
	PortTypeCodeByteOut   // binary output port
	PortTypeCodeByteInOut // binary port

	PortTypeCodeChar
	PortTypeCodeCharIn    // textual input port
	PortTypeCodeCharOut   // textual output port
	PortTypeCodeCharInOut // textual port

	PortTypeCodeAny
	PortTypeCodeAnyIn    // nonstandard, <-chan Any
	PortTypeCodeAnyOut   // nonstandard, chan<- Any
	PortTypeCodeAnyInOut // nonstandard, chan Any

	PortTypeCodeMax // maximum
)
View Source
const (
	// machine fixnums
	NumberTypeCodeS8 = iota * 2
	NumberTypeCodeS16
	NumberTypeCodeS32
	NumberTypeCodeS64

	// machine flonums
	NumberTypeCodeExactF32
	NumberTypeCodeExactF64

	// abstract numbers
	NumberTypeCodeRational
	NumberTypeCodeInteger

	// derived numbers bit field
	NumberTypeCodeBaseMask    = 0x0E
	NumberTypeCodeUnsigned    = 0x01
	NumberTypeCodeInexact     = 0x01
	NumberTypeCodePolar       = 0x01
	NumberTypeCodeComplex     = 0x10
	NumberTypeCodeDerivedMask = 0x11

	NumberTypeCodeU8        = NumberTypeCodeUnsigned | NumberTypeCodeS8
	NumberTypeCodeU16       = NumberTypeCodeUnsigned | NumberTypeCodeS16
	NumberTypeCodeU32       = NumberTypeCodeUnsigned | NumberTypeCodeS32
	NumberTypeCodeU64       = NumberTypeCodeUnsigned | NumberTypeCodeS64
	NumberTypeCodeNatural   = NumberTypeCodeUnsigned | NumberTypeCodeInteger
	NumberTypeCodeExactC64  = NumberTypeCodeComplex | NumberTypeCodeExactF32
	NumberTypeCodeExactC128 = NumberTypeCodeComplex | NumberTypeCodeExactF64
	/*
		NumberTypeCodeInexactS8  = NumberTypeCodeInexact | NumberTypeCodeS8
		NumberTypeCodeInexactS16 = NumberTypeCodeInexact | NumberTypeCodeS16
		NumberTypeCodeInexactS32 = NumberTypeCodeInexact | NumberTypeCodeS32
		NumberTypeCodeInexactS64 = NumberTypeCodeInexact | NumberTypeCodeS64
		NumberTypeCodeInexactU8  = NumberTypeCodeInexact | NumberTypeCodeU8
		NumberTypeCodeInexactU16 = NumberTypeCodeInexact | NumberTypeCodeU16
		NumberTypeCodeInexactU32 = NumberTypeCodeInexact | NumberTypeCodeU32
		NumberTypeCodeInexactU64 = NumberTypeCodeInexact | NumberTypeCodeU64
	*/
	NumberTypeCodeF32                  = NumberTypeCodeInexact | NumberTypeCodeExactF32
	NumberTypeCodeF64                  = NumberTypeCodeInexact | NumberTypeCodeExactF64
	NumberTypeCodeC64                  = NumberTypeCodeInexact | NumberTypeCodeExactC64
	NumberTypeCodeC128                 = NumberTypeCodeInexact | NumberTypeCodeExactC128
	NumberTypeCodeComplexPolar         = NumberTypeCodeComplex | NumberTypeCodePolar
	NumberTypeCodeComplexRational      = NumberTypeCodeComplex | NumberTypeCodeRational
	NumberTypeCodeComplexPolarRational = NumberTypeCodeComplexPolar | NumberTypeCodeRational

	NumberTypeCodeMax = 0x20
)
View Source
const BOOL = 57347
View Source
const CHAR = 57349
View Source
const COMMENT = 57364
View Source
const ELLIPSIS = 57362
View Source
const ID = 57346
View Source
const KEYWORD = 57363
View Source
const LABEL = 57351
View Source
const NUMBER = 57348
View Source
const QQUOTE = 57355
View Source
const QSYNTAX = 57359
View Source
const QUOTE = 57354
View Source
const STRING = 57350
View Source
const SYNTAX = 57358
View Source
const U8VECTORPAREN = 57353
View Source
const UNQUOTE = 57356
View Source
const UNQUOTES = 57357
View Source
const UNSYNTAX = 57360
View Source
const UNSYNTAXS = 57361
View Source
const VECTORPAREN = 57352

Variables

This section is empty.

Functions

func Compare

func Compare(x Num, y Num) int

func CountParens

func CountParens(s string) int

func Dump

func Dump()

func Equal

func Equal(x, y Any) bool

func GetFE

func GetFE(pc uintptr) uintptr

func GetFL

func GetFL(pc uintptr) (file string, line int)

func GetFN

func GetFN(pc uintptr) string

func GetPC

func GetPC(fn interface{}) uintptr

func GetRootPath

func GetRootPath() string

func Hash

func Hash(o Any) uintptr

func InexactEqual

func InexactEqual(x, y float64) bool

func IsBinary

func IsBinary(o Any) bool

func IsBinaryPort

func IsBinaryPort(o Any) bool

func IsBool

func IsBool(o Any) bool

func IsByte

func IsByte(o Any) bool

func IsChar

func IsChar(o Any) bool

func IsComplex

func IsComplex(a Any) bool

func IsContinuation

func IsContinuation(a interface{}) bool

func IsEmpty

func IsEmpty(a Any) bool

func IsError

func IsError(a Any) bool

func IsExact

func IsExact(a Any) bool

func IsInexact

func IsInexact(a Any) bool

func IsInputPort

func IsInputPort(o Any) bool

func IsInteger

func IsInteger(a Any) bool

func IsNull

func IsNull(o Any) bool

func IsNumber

func IsNumber(a Any) bool

func IsOutputPort

func IsOutputPort(o Any) bool

func IsPair

func IsPair(o Any) bool

func IsPort

func IsPort(o Any) bool

func IsProcedure

func IsProcedure(o Any) bool

func IsRational

func IsRational(a Any) bool

func IsReal

func IsReal(a Any) bool

func IsString

func IsString(a Any) bool

func IsSymbol

func IsSymbol(o Any) bool

func IsSyntax

func IsSyntax(kw Any, env *Env) bool

func IsTable

func IsTable(a Any) bool

func IsTextualPort

func IsTextualPort(o Any) bool

func IsType

func IsType(o Any, tag int) bool

func IsValues

func IsValues(a Any) bool

func IsVector

func IsVector(a Any) bool

func IsVoid

func IsVoid(a Any) bool

func MangleName

func MangleName(name string) string

func PointerEqual

func PointerEqual(x, y Any) bool

func SetCmdLine

func SetCmdLine(args []string)

func ToByte

func ToByte(o Any) byte

func ToError

func ToError(a interface{}) error

func ToFcmplx

func ToFcmplx(a Any) complex128

func ToFixnum

func ToFixnum(a Any) int64

func ToFlonum

func ToFlonum(a Any) float64

func TypeEqual

func TypeEqual(x, y Any) bool

func UnmangleName

func UnmangleName(mangled string) string

Types

type Any

type Any interface {
	GetType() int
	GetHash() uintptr
	Equal(Any) bool
}

Any * * This interface abstracts all data. * * The first method is used by everything. * The second and third method are used by * hashtables mostly, but also by equal?, * eqv?, eq?, and other equality functions.

func Dacos

func Dacos(a Any) Any

func Dangle

func Dangle(a Any) Any

func Dapply

func Dapply(a Any) Any

(apply proc arg1 ... restargs)

func Dasin

func Dasin(a Any) Any

func Datan

func Datan(a Any) Any

func DbinaryZKportZS

func DbinaryZKportZS(a Any) Any

func DbooleanZQZS

func DbooleanZQZS(a Any) Any

func DbooleanZS

func DbooleanZS(a Any) Any

func DbytevectorZKZRu8ZKlist

func DbytevectorZKZRu8ZKlist(a Any) Any

R6RS:bytevector->u8-list

func DbytevectorZKZRu8ZKvector

func DbytevectorZKZRu8ZKvector(a Any) Any

func DbytevectorZKcopy

func DbytevectorZKcopy(a Any) Any

func DbytevectorZKcopyZA

func DbytevectorZKcopyZA(a Any) Any

func DbytevectorZKcopyZKpartial

func DbytevectorZKcopyZKpartial(a Any) Any

func DbytevectorZKcopyZKpartialZA

func DbytevectorZKcopyZKpartialZA(a Any) Any

func DbytevectorZKlength

func DbytevectorZKlength(a Any) Any

func DbytevectorZKu8

func DbytevectorZKu8(a Any) Any

func DbytevectorZKu8ZKref

func DbytevectorZKu8ZKref(a Any) Any

func DbytevectorZKu8ZKsetZA

func DbytevectorZKu8ZKsetZA(a Any) Any

func DbytevectorZS

func DbytevectorZS(a Any) Any

func DcallZKwithZKcomposableZKcontinuation

func DcallZKwithZKcomposableZKcontinuation(a Any) Any

func DcallZKwithZKcurrentZKcontinuation

func DcallZKwithZKcurrentZKcontinuation(a Any) Any

func DcallZKwithZKescapeZKcontinuation

func DcallZKwithZKescapeZKcontinuation(a Any) (value Any)

func DcallZKwithZKport

func DcallZKwithZKport(a Any) Any

func DcallZKwithZKvalues

func DcallZKwithZKvalues(a Any) Any

func Dcar

func Dcar(a Any) Any

func Dcdr

func Dcdr(a Any) Any

func DcharZKZRinteger

func DcharZKZRinteger(a Any) Any

func DcharZKreadyZS

func DcharZKreadyZS(a Any) Any

func DcharZS

func DcharZS(a Any) Any

func DcloseZKinputZKport

func DcloseZKinputZKport(a Any) Any

func DcloseZKoutputZKport

func DcloseZKoutputZKport(a Any) Any

func DcloseZKport

func DcloseZKport(a Any) Any

func DcommandZKline

func DcommandZKline(a Any) Any

func DcomplexZS

func DcomplexZS(a Any) Any

func Dcons

func Dcons(a Any) Any

func DcontinuationZKcapture

func DcontinuationZKcapture(a Any) Any

func DcontinuationZKreturn

func DcontinuationZKreturn(a Any) Any

func Dcos

func Dcos(a Any) Any

func DcurrentZKerrorZKport

func DcurrentZKerrorZKport(a Any) Any

func DcurrentZKinputZKport

func DcurrentZKinputZKport(a Any) Any

func DcurrentZKjiffy

func DcurrentZKjiffy(a Any) Any

func DcurrentZKoutputZKport

func DcurrentZKoutputZKport(a Any) Any

func DcurrentZKsecond

func DcurrentZKsecond(a Any) Any

func Ddenominator

func Ddenominator(a Any) Any

func Ddisplay

func Ddisplay(a Any) Any

func DdroschemeZKbranch

func DdroschemeZKbranch(a Any) Any

func DdroschemeZKfloat32ZKenvironment

func DdroschemeZKfloat32ZKenvironment(a Any) Any

func DdroschemeZKfloat64ZKenvironment

func DdroschemeZKfloat64ZKenvironment(a Any) Any

func DdroschemeZKprimitiveZKenvironment

func DdroschemeZKprimitiveZKenvironment(a Any) Any

func DdroschemeZKrootZKpath

func DdroschemeZKrootZKpath(a Any) Any

func DdroschemeZKwait

func DdroschemeZKwait(a Any) Any

func DdynamicZKwind

func DdynamicZKwind(a Any) Any

func DemptyZS

func DemptyZS(a Any) Any

func DeofZKobject

func DeofZKobject(a Any) Any

func DeofZKobjectZS

func DeofZKobjectZS(a Any) Any

func DequalZS

func DequalZS(a Any) Any

func Derror

func Derror(a Any) Any

func DerrorZKobjectZKirritants

func DerrorZKobjectZKirritants(a Any) Any

func DerrorZKobjectZKmessage

func DerrorZKobjectZKmessage(a Any) Any

func DerrorZKobjectZS

func DerrorZKobjectZS(a Any) Any

func Deval

func Deval(a Any) Any

(eval expression environment)

func DevalZKliteral

func DevalZKliteral(a Any) Any

this is to compensate for failing to put an .Eval method on every object (eval-literal expression environment)

func DexactZKZRinexact

func DexactZKZRinexact(a Any) Any

func DexactZKintegerZKsqrt

func DexactZKintegerZKsqrt(a Any) Any

func DexactZS

func DexactZS(a Any) Any

func Dexit

func Dexit(a Any) Any

func Dexp

func Dexp(a Any) Any

func Dexpt

func Dexpt(a Any) Any

func Dfloor

func Dfloor(a Any) Any

func DflushZKoutputZKport

func DflushZKoutputZKport(a Any) Any

func DfoldZKleft

func DfoldZKleft(a Any) Any

(fold-left) -- derived, but useful * * (define fold-left * (case-lambda * ((proc nil) (proc nil)) * ((proc nil ls) * (if (null? ls) nil * (fold-left proc (proc nil (car ls)) (cdr ls)))) * ((proc nil . lss) * (if (null? (car lss)) nil * (let ((cars (map car lss)) * (cdrs (map cdr lss))) * (apply fold-left proc (apply proc * (append (list nil) cars)) cdrs))))))

func DfoldZKright

func DfoldZKright(a Any) Any

(fold-right) -- derived, but useful * * (define fold-right * (case-lambda * ((proc nil) (proc nil)) * ((proc nil ls) * (if (null? ls) nil * (proc (car ls) (fold-right proc nil (cdr ls))))) * ((proc nil . lss) * (if (null? (car lss)) nil * (let ((cars (map car lss)) * (cdrs (map cdr lss))) * (apply proc (append cars (list * (apply fold-right proc nil cdrs)))))))))

func DgetZKoutputZKbytevector

func DgetZKoutputZKbytevector(a Any) Any

(get-output-bytevector port)

func DgetZKoutputZKstring

func DgetZKoutputZKstring(a Any) Any

(get-output-string port)

func Dhash

func Dhash(a Any) Any

func DhashtableZKZRlist

func DhashtableZKZRlist(a Any) Any

(hash->list hashtable) -- Racket (hashtable->list hashtable) -- droscheme extension

func DhashtableZKZRvector

func DhashtableZKZRvector(a Any) Any

func DhashtableZKclearZA

func DhashtableZKclearZA(a Any) Any

(hashtable-clear! hashtable) (hashtable-clear! hashtable k) -- unimplemented

func DhashtableZKcontainsZS

func DhashtableZKcontainsZS(a Any) Any

(hashtable-contains? hashtable key)

func DhashtableZKcopy

func DhashtableZKcopy(a Any) Any

(hashtable-copy hashtable) -- unimplemented (hashtable-copy hashtable mutable) -- unimplemented

func DhashtableZKdeleteZA

func DhashtableZKdeleteZA(a Any) Any

(hashtable-delete! hashtable key)

func DhashtableZKentries

func DhashtableZKentries(a Any) Any

(hashtable-entries hashtable)

func DhashtableZKequivalenceZKfunction

func DhashtableZKequivalenceZKfunction(a Any) Any

func DhashtableZKhashZKfunction

func DhashtableZKhashZKfunction(a Any) Any

func DhashtableZKkeys

func DhashtableZKkeys(a Any) Any

(hashtable-keys hashtable)

func DhashtableZKmutableZS

func DhashtableZKmutableZS(a Any) Any

(hashtable-mutable? hashtable)

func DhashtableZKref

func DhashtableZKref(a Any) Any

(hashtable-ref hashtable key) -- droscheme extension (hashtable-ref hashtable key default)

func DhashtableZKsetZA

func DhashtableZKsetZA(a Any) Any

(hashtable-set! hashtable key value)

func DhashtableZKsize

func DhashtableZKsize(a Any) Any

(hashtable-size hashtable)

func DhashtableZKupdateZA

func DhashtableZKupdateZA(a Any) Any

(hashtable-update! hashtable key proc) -- droscheme extension (hashtable-update! hashtable key proc default)

func DhashtableZKvalues

func DhashtableZKvalues(a Any) Any

(hash-values hashtable) -- Racket (hashtable-values hashtable) -- droscheme extension

func DhashtableZS

func DhashtableZS(a Any) Any

(hashtable? obj)

func Didentity

func Didentity(a Any) Any

func DimagZKpart

func DimagZKpart(a Any) Any

func DinexactZKZRexact

func DinexactZKZRexact(a Any) Any

func DinexactZQZS

func DinexactZQZS(a Any) Any

func DinexactZS

func DinexactZS(a Any) Any

func DinputZKportZS

func DinputZKportZS(a Any) Any

func DintegerZKZRchar

func DintegerZKZRchar(a Any) Any

func DintegerZS

func DintegerZS(a Any) Any

func DinteractionZKenvironment

func DinteractionZKenvironment(a Any) Any

(interaction-environment)

func DlastZKpair

func DlastZKpair(a Any) Any

func Dlength

func Dlength(a Any) Any

func Dlist

func Dlist(a Any) Any

(list ...)

func DlistZH

func DlistZH(a Any) Any

(list* datum ... ls) (list* a b c) = '(a b . c) (list* a b '(c d)) = '(a b c d)

func DlistZHZKZRvector

func DlistZHZKZRvector(a Any) Any

(list*->vector l)

func DlistZI

func DlistZI(a Any) Any

(list+ ls datum ...) (list+ '(a b) c d) = '(a b c d)

func DlistZKZRstring

func DlistZKZRstring(a Any) Any

func DlistZKZRvector

func DlistZKZRvector(a Any) Any

(list->vector l)

func DlistZKcopy

func DlistZKcopy(a Any) Any

func DlistZKref

func DlistZKref(a Any) Any

func DlistZKtail

func DlistZKtail(a Any) Any

func DlistZS

func DlistZS(a Any) Any

func Dlog

func Dlog(a Any) Any

func Dmagnitude

func Dmagnitude(a Any) Any

func DmakeZKbytevector

func DmakeZKbytevector(a Any) Any

(make-bytevector k) (make-bytevector k byte)

func DmakeZKequalZKhashtable

func DmakeZKequalZKhashtable(a Any) Any

func DmakeZKhashtable

func DmakeZKhashtable(a Any) Any

func DmakeZKlist

func DmakeZKlist(a Any) Any

func DmakeZKparameter

func DmakeZKparameter(a Any) Any

(make-parameter init converter?)

func DmakeZKpolar

func DmakeZKpolar(a Any) Any

func DmakeZKrectangular

func DmakeZKrectangular(a Any) Any

func DmakeZKstring

func DmakeZKstring(a Any) Any

(make-string k) (make-string k char)

func DmakeZKvector

func DmakeZKvector(a Any) Any

(make-vector k fill?)

func DmakeZM

func DmakeZM(a Any) Any

func DnegativeZS

func DnegativeZS(a Any) Any

func Dnewline

func Dnewline(a Any) Any

func Dnot

func Dnot(a Any) Any

func DnullZKenvironment

func DnullZKenvironment(a Any) Any

(null-environment version)

func DnullZS

func DnullZS(a Any) Any

func DnumZH

func DnumZH(a Any) Any

func DnumZI

func DnumZI(a Any) Any

func DnumZK

func DnumZK(a Any) Any

func DnumZM

func DnumZM(a Any) Any

func DnumZP

func DnumZP(a Any) Any

func DnumZPZQ

func DnumZPZQ(a Any) Any

func DnumZQ

func DnumZQ(a Any) Any

func DnumZR

func DnumZR(a Any) Any

func DnumZRZQ

func DnumZRZQ(a Any) Any

func DnumberZKZRstring

func DnumberZKZRstring(a Any) Any

(number->string z) (number->string z radix) (number->string z radix precision)

func DnumberZKtypeZKof

func DnumberZKtypeZKof(a Any) Any

func DnumberZS

func DnumberZS(a Any) Any

func Dnumerator

func Dnumerator(a Any) Any

func DopenZKbinaryZKinputZKfile

func DopenZKbinaryZKinputZKfile(a Any) Any

(open-binary-input-file filename)

func DopenZKbinaryZKoutputZKfile

func DopenZKbinaryZKoutputZKfile(a Any) Any

(open-binary-output-file filename)

func DopenZKinputZKbytevector

func DopenZKinputZKbytevector(a Any) Any

(open-input-bytevector b)

func DopenZKinputZKfile

func DopenZKinputZKfile(a Any) Any

(open-input-file filename)

func DopenZKinputZKstring

func DopenZKinputZKstring(a Any) Any

(open-input-string s)

func DopenZKoutputZKbytevector

func DopenZKoutputZKbytevector(a Any) Any

(open-output-bytevector)

func DopenZKoutputZKfile

func DopenZKoutputZKfile(a Any) Any

(open-output-file filename)

func DopenZKoutputZKstring

func DopenZKoutputZKstring(a Any) Any

(open-output-string)

func DoutputZKportZS

func DoutputZKportZS(a Any) Any

func DpairZS

func DpairZS(a Any) Any

func DpeekZKchar

func DpeekZKchar(a Any) Any

func DpeekZKu8

func DpeekZKu8(a Any) Any

func DpointerZQZS

func DpointerZQZS(a Any) Any

func DportZKopenZS

func DportZKopenZS(a Any) Any

func DportZS

func DportZS(a Any) Any

func DpositiveZS

func DpositiveZS(a Any) Any

func DprocedureZS

func DprocedureZS(a Any) Any

func Draise

func Draise(a Any) Any

func DraiseZKcontinuable

func DraiseZKcontinuable(a Any) Any

func DrationalZS

func DrationalZS(a Any) Any

func Dread

func Dread(a Any) Any

func DreadZKbytevector

func DreadZKbytevector(a Any) Any

func DreadZKbytevectorZA

func DreadZKbytevectorZA(a Any) Any

func DreadZKchar

func DreadZKchar(a Any) Any

func DreadZKline

func DreadZKline(a Any) Any

func DreadZKu8

func DreadZKu8(a Any) Any

func DrealZKpart

func DrealZKpart(a Any) Any

func DrealZS

func DrealZS(a Any) Any

func Dround

func Dround(a Any) Any

func DschemeZKprimitiveZKenvironment

func DschemeZKprimitiveZKenvironment(a Any) Any

(scheme-primitive-environment version)

func DschemeZKreportZKenvironment

func DschemeZKreportZKenvironment(a Any) Any

(scheme-report-environment version)

func DsetZKcarZA

func DsetZKcarZA(a Any) Any

(set-car! ls expr)

func DsetZKcdrZA

func DsetZKcdrZA(a Any) Any

(set-cdr! ls expr)

func DshowZKlist

func DshowZKlist(a Any) Any

func DshowZKvector

func DshowZKvector(a Any) Any

func Dsign

func Dsign(a Any) Any

func DsimplestZKrationalZKZRexact

func DsimplestZKrationalZKZRexact(a Any) Any

func Dsin

func Dsin(a Any) Any

func Dsqrt

func Dsqrt(a Any) Any

func DstandardZKerrorZKport

func DstandardZKerrorZKport(a Any) Any

func DstandardZKinputZKport

func DstandardZKinputZKport(a Any) Any

func DstandardZKoutputZKport

func DstandardZKoutputZKport(a Any) Any

func Dstring

func Dstring(a Any) Any

func DstringZKZRlist

func DstringZKZRlist(a Any) Any

func DstringZKZRnumber

func DstringZKZRnumber(a Any) Any

(string->number string) (string->number string radix)

func DstringZKZRsymbol

func DstringZKZRsymbol(a Any) Any

func DstringZKZRutf8

func DstringZKZRutf8(a Any) Any

func DstringZKZRvector

func DstringZKZRvector(a Any) Any

func DstringZKappend

func DstringZKappend(a Any) Any

func DstringZKcopy

func DstringZKcopy(a Any) Any

func DstringZKfillZA

func DstringZKfillZA(a Any) Any

func DstringZKlength

func DstringZKlength(a Any) Any

func DstringZKref

func DstringZKref(a Any) Any

func DstringZKsetZA

func DstringZKsetZA(a Any) Any

func DstringZS

func DstringZS(a Any) Any

func Dsubstring

func Dsubstring(a Any) Any

func DsubstringZA

func DsubstringZA(a Any) Any

similar to (srfi 13) xsubstring but different (substring! from s e to at)

func DsymbolZKZRstring

func DsymbolZKZRstring(a Any) Any

func DsymbolZS

func DsymbolZS(a Any) Any

func Dtan

func Dtan(a Any) Any

func DtextualZKportZS

func DtextualZKportZS(a Any) Any

func DtypeZKof

func DtypeZKof(a Any) Any

func DtypeZQZS

func DtypeZQZS(a Any) Any

func Du8ZKlistZKZRbytevector

func Du8ZKlistZKZRbytevector(a Any) Any

R6RS:u8-list->bytevector

func Du8ZKreadyZS

func Du8ZKreadyZS(a Any) Any

func Du8ZKvectorZKZRbytevector

func Du8ZKvectorZKZRbytevector(a Any) Any

func Dutf8ZKZRstring

func Dutf8ZKZRstring(a Any) Any

func Dvalues

func Dvalues(a Any) Any

func Dvector

func Dvector(a Any) Any

func DvectorZKZRlist

func DvectorZKZRlist(a Any) Any

(vector->list v)

func DvectorZKZRlistZH

func DvectorZKZRlistZH(a Any) Any

(vector->list* v)

func DvectorZKZRstring

func DvectorZKZRstring(a Any) Any

func DvectorZKcopy

func DvectorZKcopy(a Any) Any

(vector-copy vector) (vector-copy vector start) (vector-copy vector start end) (vector-copy vector start end fill)

func DvectorZKfillZA

func DvectorZKfillZA(a Any) Any

(vector-fill! vector fill) (vector-fill! vector fill start end)

func DvectorZKforZKeach

func DvectorZKforZKeach(a Any) Any

func DvectorZKlength

func DvectorZKlength(a Any) Any

func DvectorZKmap

func DvectorZKmap(a Any) Any

func DvectorZKref

func DvectorZKref(a Any) Any

func DvectorZKsetZA

func DvectorZKsetZA(a Any) Any

func DvectorZS

func DvectorZS(a Any) Any

func Dvoid

func Dvoid(a Any) Any

func DwithZKexceptionZKhandler

func DwithZKexceptionZKhandler(a Any) Any

func Dwrite

func Dwrite(a Any) Any

func DwriteZKbytevector

func DwriteZKbytevector(a Any) Any

func DwriteZKchar

func DwriteZKchar(a Any) Any

func DwriteZKu8

func DwriteZKu8(a Any) Any

func ErrorToPanic

func ErrorToPanic(value Any, err error) Any

func Eval

func Eval(expr Any, env *Env) (value Any, err error)

(eval expr env)

func KapplyZKsyntax

func KapplyZKsyntax(kw, st Any, env *Env) Any

(apply-syntax keyword list)

func Kbegin

func Kbegin(kw, st Any, env *Env) Any

(begin ...)

func KcaseZKlambda

func KcaseZKlambda(kw, st Any, env *Env) Any

func KcurrentZKenvironment

func KcurrentZKenvironment(kw, st Any, env *Env) Any

(current-environment) -- for debug only

func Kdefine

func Kdefine(kw, st Any, env *Env) Any

(define var) (define var expr) (define (var formals) body) (define (var . formals) body)

func KdefineZKlibrary

func KdefineZKlibrary(kw, st Any, env *Env) Any

(define-library (module name) ...) // R7RS

func KdefineZKmacro

func KdefineZKmacro(kw, st Any, env *Env) Any

func KdefineZKsyntax

func KdefineZKsyntax(kw, st Any, env *Env) Any

func KdefineZKvalues

func KdefineZKvalues(kw, st Any, env *Env) Any

func Kdo

func Kdo(kw, st Any, env *Env) Any

func KdumpZKenvironment

func KdumpZKenvironment(kw, st Any, env *Env) Any

(dump-environment) -- for debug only

func Kif

func Kif(kw, st Any, env *Env) Any

(if c texpr) (if c texpr fexpr)

func Klambda

func Klambda(kw, st Any, env *Env) Any

(lambda var body) (lambda (formals) body) (lambda (formals . var) body)

func Klet

func Klet(kw, st Any, env *Env) Any

(let)

func KletZH

func KletZH(kw, st Any, env *Env) Any

(let*)

func KletZKsyntax

func KletZKsyntax(kw, st Any, env *Env) Any

(let-syntax)

func KletZKvalues

func KletZKvalues(kw, st Any, env *Env) Any

(let-values)

func Kletrec

func Kletrec(kw, st Any, env *Env) Any

(letrec)

func KletrecZKsyntax

func KletrecZKsyntax(kw, st Any, env *Env) Any

(letrec-syntax)

func KletrecZKvalues

func KletrecZKvalues(kw, st Any, env *Env) Any

(letrec-values)

func Klibrary

func Klibrary(kw, st Any, env *Env) Any

(library (module name) ...) // R6RS

func Kload

func Kload(kw, st Any, env *Env) Any

func Kparameterize

func Kparameterize(kw, st Any, env *Env) Any

func Kquasiquote

func Kquasiquote(kw, st Any, env *Env) Any

(quasiquote expr)

func Kquote

func Kquote(kw, st Any, env *Env) Any

(quote expr)

func KsetZA

func KsetZA(kw, st Any, env *Env) Any

(set! var expr)

func KsyntaxZKcase

func KsyntaxZKcase(kw, st Any, env *Env) Any

func KsyntaxZKerror

func KsyntaxZKerror(kw, st Any, env *Env) Any

func KsyntaxZKrules

func KsyntaxZKrules(kw, st Any, env *Env) Any

func Kunquote

func Kunquote(kw, st Any, env *Env) Any

func KunquoteZKsplicing

func KunquoteZKsplicing(kw, st Any, env *Env) Any

func Load

func Load(filename string, env *Env) (value Any, err error)

func NewBegin

func NewBegin(body Any, env *Env) Any

func NewEval

func NewEval(body Any, env *Env) Any

func NewKeyword

func NewKeyword(key, value Any) Any

func NewLabel

func NewLabel(l, d Any) Any

func NewLambda

func NewLambda(rest Any, env *Env) Any

func NewPrim

func NewPrim(fn func(Any) Any) Any

func NewValues

func NewValues(a []Any) Any

func OpenBIFile

func OpenBIFile(filename string) Any

(open-binary-input-file f)

func OpenBOFile

func OpenBOFile(filename string) Any

(open-binary-output-file f)

func OpenTIFile

func OpenTIFile(filename string) Any

(open-input-file f)

func OpenTOFile

func OpenTOFile(filename string) Any

(open-output-file f)

func PanicToError

func PanicToError(expr Any) (value Any, err error)

func ReadPort

func ReadPort(port Any) (value Any, err error)

func ReadString

func ReadString(input string) (Any, error)

func ToString

func ToString(s string) Any

func Void

func Void() Any

type Applier

type Applier interface {
	// (procedure).Apply(arguments)
	Apply(Any) Any
}

type ArithNum

type ArithNum interface {
	Abs(x Num) Num
	Add(x, y Num) Num
	Copy() Num
	Mul(x, y Num) Num
	Neg(x Num) Num
	One() Num
	Quo(x, y Num) Num
	Set(x Num) Num
	Sign() int
	Sub(x, y Num) Num
	Zero() Num
}

type BIPort

type BIPort interface {
	io.ByteReader
	io.Reader
	BytePeeker
	Peeker
}

type BOPort

type BOPort interface {
	io.Writer
}

type BPort

type BPort interface {
	BIPort
	BOPort
}

type BaseNum

type BaseNum interface {
	Any
	GetNumberType() int
}

type BytePeeker

type BytePeeker interface {
	PeekByte() (c byte, err error)
	ReadyByte() bool
}

type Closer

type Closer interface {
	io.Closer
	Closed() bool
}

type ComplexNum

type ComplexNum interface {
	Num
	Real() RealNum
	Imag() RealNum
	Scale() RealNum
	Angle() RealNum
}

func NewComplex

func NewComplex(x, y Num) ComplexNum

func NewComplexPolar

func NewComplexPolar(s, a Num) ComplexNum

type Cont

type Cont uintptr

type Env

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

func BuiltinEnv

func BuiltinEnv() *Env

(ds builtin)

func EmptyEnv

func EmptyEnv() *Env

func (*Env) DefMacro

func (env *Env) DefMacro(symbol, body Any) Any

func (*Env) DefMatch

func (env *Env) DefMatch(symbol, value Any) Any

func (*Env) DefSyntax

func (env *Env) DefSyntax(symbol, rules Any) Any

func (*Env) DefValue

func (env *Env) DefValue(symbol, body Any) (id string, value Any)

func (*Env) Define

func (env *Env) Define(symbol, body Any) Any

func (*Env) Equal

func (env *Env) Equal(a Any) bool

func (*Env) Extend

func (env *Env) Extend() *Env

func (*Env) GetHash

func (env *Env) GetHash() uintptr

func (*Env) GetType

func (env *Env) GetType() int

func (*Env) Has

func (env *Env) Has(symbol Any) bool

func (*Env) Ref

func (env *Env) Ref(symbol Any) Any

func (*Env) Set

func (env *Env) Set(symbol, value Any) Any

func (*Env) String

func (env *Env) String() string

func (*Env) Update

func (env *Env) Update(child *Env) *Env

type Error

type Error interface {
	error
	Irritants() Any
}

type Evaler

type Evaler interface {
	// (object).Eval(environment)
	Eval(*Env) Any
}

type ExactNum

type ExactNum interface {
	Num
	Inexact() InexactNum
}

type Flusher

type Flusher interface {
	Flush() error
}

implemented by bufio.Writer

type IPort

type IPort interface {
	BIPort
	TIPort
}

type InexactNum

type InexactNum interface {
	Num
	Exact() ExactNum
	Prec() int
}

type IntNum

type IntNum interface {
	Num
}

type Lexer

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

func (*Lexer) Error

func (lex *Lexer) Error(e string)

func (*Lexer) Lex

func (lex *Lexer) Lex(lval *yySymType) int

type LineReader

type LineReader interface {
	ReadLine() (line []rune, err error)
}

type List

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

func (*List) Equal

func (o *List) Equal(a Any) bool

func (*List) Eval

func (o *List) Eval(env *Env) Any

func (*List) First

func (o *List) First() Any

func (*List) GetHash

func (o *List) GetHash() uintptr

func (*List) GetType

func (o *List) GetType() int

func (*List) Match

func (p *List) Match(syntax Any, env *Env) bool

func (*List) Replace

func (t *List) Replace(env *Env) Any

func (*List) Rest

func (o *List) Rest() Any

func (*List) String

func (o *List) String() string

func (*List) ToVector

func (o *List) ToVector() Any

type Matcher

type Matcher interface {
	Match(syntax Any, env *Env) bool
}

Matcher * * This interface represents the first phase * of (syntax-rules) transformations. It is * similar to Equal, except that it takes an * environment, which is normally empty, and * is used as an extra return value in which * pattern variables are bound. * * The pattern variables are used by the next * phase, so in order to save energy later, we * assign any pattern variables found in the * object that implements this method and then * store them in env. The same environment is * also used for literals, which must be given * to the Match method in the form x=x.

type Num

type Num interface {
	BaseNum
	Add(Num) Num
	Sub(Num) Num
	Mul(Num) Num
	Div(Num) Num
}

func NewInteger

func NewInteger(n Num) Num

type OPort

type OPort interface {
	BOPort
	TOPort
	Flusher
}

type Peeker

type Peeker interface {
	Peek(n int) (c []byte, err error)
}

implemented by bufio.Reader

type Port

type Port interface {
	Any
	GetPortType() int
	Closer
}

type RealNum

type RealNum interface {
	Num
	Cmp(Num) int // -1, 0, 1
	MakeRect(RealNum) ComplexNum
	MakePolar(RealNum) ComplexNum
	RTN() IntNum // floor
	RTE() IntNum // round
}

type Replacer

type Replacer interface {
	Replace(env *Env) Any
}

Replacer * * This interface represents the second phase * of (syntax-rules) transformations. It is * similar to Eval, except in the way that the * environment is used. Instead of raising an * error every time a symbol is unbound, it * continues silently, and only replaces those * symbols which are in the environment. * * The pattern variables are given in env by the * Match method, in such a way that we can treat * literals the same as pattern variables, since * they are of the form x=x (see above). Hence, * the literals can safely be replaced just like * the pattern variables. This is the magic * I was hoping to describe in this comment.

type RunePeeker

type RunePeeker interface {
	PeekRune() (r rune, size int, err error)
	ReadyRune() bool
}

type RunesWriter

type RunesWriter interface {
	WriteRunes(p []rune) (n int, err error)
}

similar to io.WriteString

type SBinary

type SBinary []byte

func NewBinary

func NewBinary(b []byte) SBinary

func (SBinary) Equal

func (o SBinary) Equal(a Any) bool

func (SBinary) GetHash

func (o SBinary) GetHash() uintptr

func (SBinary) GetType

func (o SBinary) GetType() int

func (SBinary) Match

func (o SBinary) Match(syntax Any, env *Env) bool

func (SBinary) Ref

func (o SBinary) Ref(k Any) Any

func (SBinary) Replace

func (o SBinary) Replace(env *Env) Any

func (SBinary) Set

func (o SBinary) Set(k, v Any) Any

func (SBinary) String

func (o SBinary) String() string

type SBool

type SBool bool

func (SBool) Equal

func (o SBool) Equal(a Any) bool

func (SBool) GetHash

func (o SBool) GetHash() uintptr

func (SBool) GetType

func (o SBool) GetType() int

func (SBool) Match

func (o SBool) Match(syntax Any, env *Env) bool

func (SBool) Replace

func (o SBool) Replace(env *Env) Any

func (SBool) String

func (o SBool) String() string

type SBytePort

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

func (*SBytePort) Close

func (o *SBytePort) Close() error

func (*SBytePort) Closed

func (o *SBytePort) Closed() bool

func (*SBytePort) Equal

func (o *SBytePort) Equal(a Any) bool

func (*SBytePort) GetHash

func (o *SBytePort) GetHash() uintptr

func (*SBytePort) GetPortType

func (o *SBytePort) GetPortType() int

func (*SBytePort) GetType

func (o *SBytePort) GetType() int

func (*SBytePort) Peek

func (o *SBytePort) Peek(n int) (b []byte, err error)

func (*SBytePort) PeekByte

func (o *SBytePort) PeekByte() (b byte, err error)

func (*SBytePort) PeekRune

func (o *SBytePort) PeekRune() (r rune, err error)

func (*SBytePort) Read

func (o *SBytePort) Read(p []byte) (n int, err error)

func (*SBytePort) ReadByte

func (o *SBytePort) ReadByte() (c byte, err error)

func (*SBytePort) ReadLine

func (o *SBytePort) ReadLine() (line []rune, err error)

func (*SBytePort) ReadRune

func (o *SBytePort) ReadRune() (r rune, size int, err error)

type SCaseSyntax

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

func (SCaseSyntax) Equal

func (o SCaseSyntax) Equal(a Any) bool

func (SCaseSyntax) GetHash

func (o SCaseSyntax) GetHash() uintptr

func (SCaseSyntax) GetType

func (o SCaseSyntax) GetType() int

func (SCaseSyntax) String

func (o SCaseSyntax) String() string

func (SCaseSyntax) Transform

func (o SCaseSyntax) Transform(kw, st Any, env *Env) Any

type SChar

type SChar rune

func (SChar) Equal

func (o SChar) Equal(a Any) bool

func (SChar) GetHash

func (o SChar) GetHash() uintptr

func (SChar) GetType

func (o SChar) GetType() int

func (SChar) Match

func (o SChar) Match(syntax Any, env *Env) bool

func (SChar) Replace

func (o SChar) Replace(env *Env) Any

func (SChar) String

func (o SChar) String() string

type SCharPort

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

func (*SCharPort) Close

func (o *SCharPort) Close() error

func (*SCharPort) Closed

func (o *SCharPort) Closed() bool

func (*SCharPort) Equal

func (o *SCharPort) Equal(a Any) bool

func (*SCharPort) Flush

func (o *SCharPort) Flush() error

func (*SCharPort) GetHash

func (o *SCharPort) GetHash() uintptr

func (*SCharPort) GetPortType

func (o *SCharPort) GetPortType() int

func (*SCharPort) GetType

func (o *SCharPort) GetType() int

func (*SCharPort) Peek

func (o *SCharPort) Peek(n int) (b []byte, err error)

func (*SCharPort) PeekByte

func (o *SCharPort) PeekByte() (b byte, err error)

func (*SCharPort) PeekRune

func (o *SCharPort) PeekRune() (r rune, err error)

func (*SCharPort) Read

func (o *SCharPort) Read(p []byte) (n int, err error)

func (*SCharPort) ReadByte

func (o *SCharPort) ReadByte() (c byte, err error)

func (*SCharPort) ReadLine

func (o *SCharPort) ReadLine() (line []rune, err error)

func (*SCharPort) ReadRune

func (o *SCharPort) ReadRune() (r rune, size int, err error)

func (*SCharPort) Write

func (o *SCharPort) Write(c []byte) (n int, err error)

func (*SCharPort) WriteRunes

func (o *SCharPort) WriteRunes(r []rune) (n int, err error)

type SComplex

type SComplex [2]SRational

func NewComplexI

func NewComplexI() SComplex

func (SComplex) Add

func (o SComplex) Add(n Num) Num

func (SComplex) Angle

func (o SComplex) Angle() RealNum

func (SComplex) Conj

func (o SComplex) Conj() Num

func (SComplex) Div

func (o SComplex) Div(n Num) Num

func (SComplex) Equal

func (o SComplex) Equal(n Any) bool

func (SComplex) GetHash

func (o SComplex) GetHash() uintptr

func (SComplex) GetNumberType

func (o SComplex) GetNumberType() int

func (SComplex) GetType

func (o SComplex) GetType() int

func (SComplex) Imag

func (o SComplex) Imag() RealNum

func (SComplex) Mod

func (o SComplex) Mod(n Num) Num

func (SComplex) Mul

func (o SComplex) Mul(n Num) Num

func (SComplex) Real

func (o SComplex) Real() RealNum

func (SComplex) Scale

func (o SComplex) Scale() RealNum

func (SComplex) Shl

func (o SComplex) Shl(n Num) Num

func (SComplex) Shr

func (o SComplex) Shr(n Num) Num

func (SComplex) String

func (o SComplex) String() string

func (SComplex) Sub

func (o SComplex) Sub(n Num) Num

type SComplexPolar

type SComplexPolar [2]SRational

func (SComplexPolar) Add

func (o SComplexPolar) Add(n Num) Num

func (SComplexPolar) Angle

func (o SComplexPolar) Angle() RealNum

func (SComplexPolar) Cmp

func (o SComplexPolar) Cmp(n Num) Num

func (SComplexPolar) Div

func (o SComplexPolar) Div(n Num) Num

func (SComplexPolar) Equal

func (o SComplexPolar) Equal(n Any) bool

func (SComplexPolar) GetHash

func (o SComplexPolar) GetHash() uintptr

func (SComplexPolar) GetNumberType

func (o SComplexPolar) GetNumberType() int

func (SComplexPolar) GetType

func (o SComplexPolar) GetType() int

func (SComplexPolar) Imag

func (o SComplexPolar) Imag() RealNum

func (SComplexPolar) Mod

func (o SComplexPolar) Mod(n Num) Num

func (SComplexPolar) Mul

func (o SComplexPolar) Mul(n Num) Num

func (SComplexPolar) Real

func (o SComplexPolar) Real() RealNum

func (SComplexPolar) Scale

func (o SComplexPolar) Scale() RealNum

func (SComplexPolar) Shl

func (o SComplexPolar) Shl(n Num) Num

func (SComplexPolar) Shr

func (o SComplexPolar) Shr(n Num) Num

func (SComplexPolar) String

func (o SComplexPolar) String() string

func (SComplexPolar) Sub

func (o SComplexPolar) Sub(n Num) Num

type SCont

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

func (SCont) Apply

func (o SCont) Apply(a Any) Any

func (SCont) Equal

func (o SCont) Equal(a Any) bool

func (SCont) GetHash

func (o SCont) GetHash() uintptr

func (SCont) GetType

func (o SCont) GetType() int

func (SCont) String

func (o SCont) String() string

type SError

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

func MakeError

func MakeError(err error) SError

func NewError

func NewError(msg, irr Any) SError

func (SError) Equal

func (o SError) Equal(a Any) bool

func (SError) Error

func (o SError) Error() string

func (SError) GetErrorType

func (o SError) GetErrorType() int

func (SError) GetHash

func (o SError) GetHash() uintptr

func (SError) GetType

func (o SError) GetType() int

func (SError) Irritants

func (o SError) Irritants() Any

type SFilePort

type SFilePort struct {
	*os.File
	// contains filtered or unexported fields
}

func (SFilePort) Closed

func (o SFilePort) Closed() bool

func (SFilePort) Equal

func (o SFilePort) Equal(a Any) bool

func (SFilePort) Flush

func (o SFilePort) Flush() error

func (SFilePort) GetHash

func (o SFilePort) GetHash() uintptr

func (SFilePort) GetPortType

func (o SFilePort) GetPortType() int

func (SFilePort) GetType

func (o SFilePort) GetType() int

func (SFilePort) ReadByte

func (o SFilePort) ReadByte() (c byte, err error)

func (SFilePort) ReadRune

func (o SFilePort) ReadRune() (r rune, size int, err error)

func (SFilePort) ReadyByte

func (o SFilePort) ReadyByte() bool

func (SFilePort) ReadyRune

func (o SFilePort) ReadyRune() bool

func (SFilePort) String

func (o SFilePort) String() string

func (SFilePort) WriteRunes

func (o SFilePort) WriteRunes(r []rune) (n int, err error)

type SFixnum

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

func (SFixnum) Equal

func (o SFixnum) Equal(a Any) bool

func (o Sfloat32) Equal(a Any) bool { return false } func (o Sfloat64) Equal(a Any) bool { return false } func (o Scomplex64) Equal(a Any) bool { return false } func (o Scomplex128) Equal(a Any) bool { return false }

func (SFixnum) GetHash

func (o SFixnum) GetHash() uintptr

func (SFixnum) GetNumberType

func (o SFixnum) GetNumberType() int

func (SFixnum) GetType

func (o SFixnum) GetType() int

derived numbers

type SFlonum

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

func (SFlonum) Equal

func (o SFlonum) Equal(a Any) bool

func (SFlonum) GetHash

func (o SFlonum) GetHash() uintptr

func (SFlonum) GetNumberType

func (o SFlonum) GetNumberType() int

func (SFlonum) GetType

func (o SFlonum) GetType() int

type SInteger

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

func NewInteger64

func NewInteger64(n int64) SInteger

func ToInteger

func ToInteger(n Num) SInteger

func (SInteger) Add

func (o SInteger) Add(n Num) Num

func (SInteger) Cmp

func (o SInteger) Cmp(n Num) int

func (SInteger) Div

func (o SInteger) Div(n Num) Num

func (SInteger) Equal

func (o SInteger) Equal(n Any) bool

func (SInteger) GetHash

func (o SInteger) GetHash() uintptr

func (SInteger) GetNumberType

func (o SInteger) GetNumberType() int

func (SInteger) GetType

func (o SInteger) GetType() int

func (SInteger) MakePolar

func (o SInteger) MakePolar(n RealNum) ComplexNum

func (SInteger) MakeRect

func (o SInteger) MakeRect(n RealNum) ComplexNum

func (SInteger) Mod

func (o SInteger) Mod(n Num) Num

func (SInteger) Mul

func (o SInteger) Mul(n Num) Num

func (SInteger) RTE

func (o SInteger) RTE() IntNum

func (SInteger) RTN

func (o SInteger) RTN() IntNum

func (SInteger) Shl

func (o SInteger) Shl(n Num) Num

func (SInteger) Shr

func (o SInteger) Shr(n Num) Num

func (SInteger) String

func (o SInteger) String() string

func (SInteger) Sub

func (o SInteger) Sub(n Num) Num

type SLabel

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

func (SLabel) Equal

func (o SLabel) Equal(a Any) bool

func (SLabel) GetHash

func (o SLabel) GetHash() uintptr

func (SLabel) GetType

func (o SLabel) GetType() int

func (SLabel) String

func (o SLabel) String() string

type SNull

type SNull struct{}

func (SNull) Equal

func (_ SNull) Equal(a Any) bool

func (SNull) Eval

func (o SNull) Eval(env *Env) Any

func (SNull) GetHash

func (o SNull) GetHash() uintptr

func (SNull) GetType

func (o SNull) GetType() int

func (SNull) Match

func (o SNull) Match(syntax Any, env *Env) bool

func (SNull) Replace

func (o SNull) Replace(env *Env) Any

func (SNull) String

func (_ SNull) String() string

func (SNull) ToVector

func (o SNull) ToVector() Any

type SPrim

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

func (SPrim) Apply

func (o SPrim) Apply(a Any) Any

func (SPrim) Equal

func (o SPrim) Equal(a Any) bool

func (SPrim) GetHash

func (o SPrim) GetHash() uintptr

func (SPrim) GetType

func (o SPrim) GetType() int

func (SPrim) String

func (o SPrim) String() string

type SPrimSyntax

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

func (SPrimSyntax) Equal

func (o SPrimSyntax) Equal(a Any) bool

func (SPrimSyntax) GetHash

func (o SPrimSyntax) GetHash() uintptr

func (SPrimSyntax) GetType

func (o SPrimSyntax) GetType() int

func (SPrimSyntax) String

func (o SPrimSyntax) String() string

func (SPrimSyntax) Transform

func (o SPrimSyntax) Transform(kw, st Any, env *Env) Any

type SProc

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

func (SProc) Apply

func (o SProc) Apply(a Any) Any

func (SProc) Equal

func (o SProc) Equal(a Any) bool

func (SProc) GetHash

func (o SProc) GetHash() uintptr

func (SProc) GetType

func (o SProc) GetType() int

func (SProc) String

func (o SProc) String() string

func (SProc) ToList

func (o SProc) ToList() Any

type SProcSyntax

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

func (SProcSyntax) Equal

func (o SProcSyntax) Equal(a Any) bool

func (SProcSyntax) GetHash

func (o SProcSyntax) GetHash() uintptr

func (SProcSyntax) GetType

func (o SProcSyntax) GetType() int

func (SProcSyntax) String

func (o SProcSyntax) String() string

func (SProcSyntax) Transform

func (o SProcSyntax) Transform(kw, st Any, env *Env) Any

type SRational

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

func NewRational

func NewRational(n, d Num) SRational

func NewRational64

func NewRational64(n, d int64) SRational

func ToRational

func ToRational(n Num) SRational

func (SRational) Add

func (o SRational) Add(n Num) Num

func (SRational) Cmp

func (o SRational) Cmp(n Num) int

func (SRational) Cmp0

func (o SRational) Cmp0() int

func (SRational) Div

func (o SRational) Div(n Num) Num

func (SRational) Dmtr

func (o SRational) Dmtr() Num

func (SRational) Equal

func (o SRational) Equal(n Any) bool

func (SRational) GetHash

func (o SRational) GetHash() uintptr

func (SRational) GetNumberType

func (o SRational) GetNumberType() int

func (SRational) GetType

func (o SRational) GetType() int

func (SRational) MakePolar

func (o SRational) MakePolar(n RealNum) ComplexNum

func (SRational) MakeRect

func (o SRational) MakeRect(n RealNum) ComplexNum

func (SRational) Mod

func (o SRational) Mod(n Num) Num

func (SRational) Mul

func (o SRational) Mul(n Num) Num

func (SRational) Nmtr

func (o SRational) Nmtr() Num

func (SRational) RTE

func (o SRational) RTE() IntNum

func (SRational) RTN

func (o SRational) RTN() IntNum

func (SRational) Shl

func (o SRational) Shl(n Num) Num

func (SRational) Shr

func (o SRational) Shr(n Num) Num

func (SRational) String

func (o SRational) String() string

func (SRational) Sub

func (o SRational) Sub(n Num) Num

func (SRational) Zero

func (o SRational) Zero() Num

type SRuleSyntax

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

func (SRuleSyntax) Equal

func (o SRuleSyntax) Equal(a Any) bool

func (SRuleSyntax) GetHash

func (o SRuleSyntax) GetHash() uintptr

func (SRuleSyntax) GetType

func (o SRuleSyntax) GetType() int

func (SRuleSyntax) String

func (o SRuleSyntax) String() string

func (SRuleSyntax) Transform

func (o SRuleSyntax) Transform(kw, st Any, env *Env) Any

RuleSyntax.Transform * *

type SString

type SString []rune

func NewString

func NewString(s []rune) SString

func (SString) Equal

func (o SString) Equal(a Any) bool

func (SString) GetHash

func (o SString) GetHash() uintptr

func (SString) GetType

func (o SString) GetType() int

func (SString) GoString

func (o SString) GoString() string

func (SString) Match

func (o SString) Match(syntax Any, env *Env) bool

func (SString) Ref

func (o SString) Ref(k Any) Any

func (SString) Replace

func (o SString) Replace(env *Env) Any

func (SString) Set

func (o SString) Set(k, v Any) Any

func (SString) String

func (o SString) String() string

type SSymbol

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

func NewSymbol

func NewSymbol(s string) SSymbol

func (SSymbol) Equal

func (o SSymbol) Equal(a Any) bool

func (SSymbol) Eval

func (o SSymbol) Eval(env *Env) Any

func (SSymbol) GetHash

func (o SSymbol) GetHash() uintptr

func (SSymbol) GetType

func (o SSymbol) GetType() int

func (SSymbol) Match

func (o SSymbol) Match(syntax Any, env *Env) bool

func (SSymbol) Replace

func (o SSymbol) Replace(env *Env) Any

func (SSymbol) String

func (o SSymbol) String() string

type STable

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

func MakeTable

func MakeTable(hash, equiv, k Any) STable

func (STable) Delete

func (o STable) Delete(k Any)

func (STable) Entries

func (o STable) Entries() (keys []Any, values []Any)

func (STable) Equal

func (o STable) Equal(a Any) bool

func (STable) GetHash

func (o STable) GetHash() uintptr

func (STable) GetType

func (o STable) GetType() int

func (STable) Items

func (o STable) Items() []Any

func (STable) Keys

func (o STable) Keys() []Any

func (STable) Ref

func (o STable) Ref(k Any) Any

func (STable) Set

func (o STable) Set(k, v Any)

func (STable) String

func (o STable) String() string

func (STable) Values

func (o STable) Values() []Any

type SType

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

func (SType) Equal

func (o SType) Equal(t Any) bool

func (SType) GetPortType

func (o SType) GetPortType() int

this does not make SType a port because we do not implement the Read/Write methods

func (SType) GetType

func (o SType) GetType() int

type SValues

type SValues []Any

func (SValues) Equal

func (o SValues) Equal(a Any) bool

func (SValues) First

func (o SValues) First() Any

func (SValues) GetHash

func (o SValues) GetHash() uintptr

func (SValues) GetType

func (o SValues) GetType() int

func (SValues) Rest

func (o SValues) Rest() SValues

func (SValues) String

func (o SValues) String() string

type SVector

type SVector []Any

func NewVector

func NewVector(a []Any) SVector

func (SVector) Equal

func (o SVector) Equal(a Any) bool

func (SVector) Eval

func (o SVector) Eval(env *Env) Any

func (SVector) GetHash

func (o SVector) GetHash() uintptr

func (SVector) GetType

func (o SVector) GetType() int

func (SVector) Ref

func (o SVector) Ref(k Any) Any

func (SVector) Set

func (o SVector) Set(k, v Any) Any

func (SVector) String

func (o SVector) String() string

func (SVector) ToList

func (o SVector) ToList() Any

type SVoid

type SVoid struct{}

func (SVoid) Equal

func (_ SVoid) Equal(a Any) bool

func (SVoid) GetHash

func (o SVoid) GetHash() uintptr

func (SVoid) GetType

func (o SVoid) GetType() int

func (SVoid) String

func (_ SVoid) String() string

type Scomplex128

type Scomplex128 complex128

func (Scomplex128) Add

func (o Scomplex128) Add(n Num) Num

func (Scomplex128) Angle

func (o Scomplex128) Angle() RealNum

func (Scomplex128) Div

func (o Scomplex128) Div(n Num) Num

func (Scomplex128) Equal

func (o Scomplex128) Equal(n Any) bool

func (Scomplex128) GetHash

func (o Scomplex128) GetHash() uintptr

func (Scomplex128) GetNumberType

func (o Scomplex128) GetNumberType() int

func (Scomplex128) GetType

func (o Scomplex128) GetType() int

func (Scomplex128) Imag

func (o Scomplex128) Imag() RealNum

func (Scomplex128) Mod

func (o Scomplex128) Mod(n Num) Num

func (Scomplex128) Mul

func (o Scomplex128) Mul(n Num) Num

func (Scomplex128) Real

func (o Scomplex128) Real() RealNum

func (Scomplex128) Scale

func (o Scomplex128) Scale() RealNum

func (Scomplex128) Shl

func (o Scomplex128) Shl(n Num) Num

func (Scomplex128) Shr

func (o Scomplex128) Shr(n Num) Num

func (Scomplex128) String

func (o Scomplex128) String() string

func (Scomplex128) Sub

func (o Scomplex128) Sub(n Num) Num

type Scomplex64

type Scomplex64 complex64

func (Scomplex64) Angle

func (o Scomplex64) Angle() RealNum

func (Scomplex64) Equal

func (o Scomplex64) Equal(n Any) bool

func (Scomplex64) GetHash

func (o Scomplex64) GetHash() uintptr

func (Scomplex64) GetNumberType

func (o Scomplex64) GetNumberType() int

func (Scomplex64) GetType

func (o Scomplex64) GetType() int

func (Scomplex64) Imag

func (o Scomplex64) Imag() RealNum

func (Scomplex64) Real

func (o Scomplex64) Real() RealNum

func (Scomplex64) Scale

func (o Scomplex64) Scale() RealNum

func (Scomplex64) String

func (o Scomplex64) String() string

C64

type Sfloat32

type Sfloat32 float32

inexact

func (Sfloat32) Add

func (o Sfloat32) Add(n Num) Num

func (Sfloat32) Cmp

func (o Sfloat32) Cmp(n Num) int

func (Sfloat32) Div

func (o Sfloat32) Div(n Num) Num

func (Sfloat32) Equal

func (o Sfloat32) Equal(n Any) bool

func (Sfloat32) GetHash

func (o Sfloat32) GetHash() uintptr

func (Sfloat32) GetNumberType

func (o Sfloat32) GetNumberType() int

func (Sfloat32) GetType

func (o Sfloat32) GetType() int

func (Sfloat32) MakePolar

func (o Sfloat32) MakePolar(n RealNum) ComplexNum

func (Sfloat32) MakeRect

func (o Sfloat32) MakeRect(n RealNum) ComplexNum

func (Sfloat32) Mod

func (o Sfloat32) Mod(n Num) Num

func (Sfloat32) Mul

func (o Sfloat32) Mul(n Num) Num

func (Sfloat32) RTE

func (o Sfloat32) RTE() IntNum

func (Sfloat32) RTN

func (o Sfloat32) RTN() IntNum

func (Sfloat32) Shl

func (o Sfloat32) Shl(n Num) Num

func (Sfloat32) Shr

func (o Sfloat32) Shr(n Num) Num

func (Sfloat32) String

func (o Sfloat32) String() string

func (Sfloat32) Sub

func (o Sfloat32) Sub(n Num) Num

type Sfloat64

type Sfloat64 float64 // flonum

func (Sfloat64) Add

func (o Sfloat64) Add(n Num) Num

func (Sfloat64) ArcCos

func (o Sfloat64) ArcCos() Num

func (Sfloat64) ArcSin

func (o Sfloat64) ArcSin() Num

func (Sfloat64) ArcTan

func (o Sfloat64) ArcTan(n Num) Num

func (Sfloat64) Cmp

func (o Sfloat64) Cmp(n Num) int

func (Sfloat64) Cos

func (o Sfloat64) Cos() Num

func (Sfloat64) Div

func (o Sfloat64) Div(n Num) Num

func (Sfloat64) Equal

func (o Sfloat64) Equal(n Any) bool

func (Sfloat64) Exp

func (o Sfloat64) Exp() Num

func (Sfloat64) GetHash

func (o Sfloat64) GetHash() uintptr

func (Sfloat64) GetNumberType

func (o Sfloat64) GetNumberType() int

func (Sfloat64) GetType

func (o Sfloat64) GetType() int

func (Sfloat64) Ln

func (o Sfloat64) Ln() Num

func (Sfloat64) Log

func (o Sfloat64) Log(n Num) Num

func (Sfloat64) MakePolar

func (o Sfloat64) MakePolar(n RealNum) ComplexNum

func (Sfloat64) MakeRect

func (o Sfloat64) MakeRect(n RealNum) ComplexNum

func (Sfloat64) Mod

func (o Sfloat64) Mod(n Num) Num

func (Sfloat64) Mul

func (o Sfloat64) Mul(n Num) Num

func (Sfloat64) Pow

func (o Sfloat64) Pow(n Num) Num

func (Sfloat64) RNN

func (o Sfloat64) RNN() IntNum

func (Sfloat64) RTE

func (o Sfloat64) RTE() IntNum

func (Sfloat64) RTN

func (o Sfloat64) RTN() IntNum

func (Sfloat64) Shl

func (o Sfloat64) Shl(n Num) Num

func (Sfloat64) Shr

func (o Sfloat64) Shr(n Num) Num

func (Sfloat64) Sin

func (o Sfloat64) Sin() Num

func (Sfloat64) Sqrt

func (o Sfloat64) Sqrt() Num

func (Sfloat64) String

func (o Sfloat64) String() string

func (Sfloat64) Sub

func (o Sfloat64) Sub(n Num) Num

func (Sfloat64) Tan

func (o Sfloat64) Tan() Num

type Sint16

type Sint16 int16

func (Sint16) Equal

func (o Sint16) Equal(a Any) bool

func (Sint16) GetHash

func (o Sint16) GetHash() uintptr

func (Sint16) GetNumberType

func (o Sint16) GetNumberType() int

func (Sint16) GetType

func (o Sint16) GetType() int

type Sint32

type Sint32 int32

func (Sint32) Add

func (o Sint32) Add(n Num) Num

func (Sint32) Cmp

func (o Sint32) Cmp(n Num) int

func (Sint32) Div

func (o Sint32) Div(n Num) Num

func (Sint32) Equal

func (o Sint32) Equal(n Any) bool

func (Sint32) GetHash

func (o Sint32) GetHash() uintptr

func (Sint32) GetNumberType

func (o Sint32) GetNumberType() int

func (Sint32) GetType

func (o Sint32) GetType() int

func (Sint32) Mod

func (o Sint32) Mod(n Num) Num

func (Sint32) Mul

func (o Sint32) Mul(n Num) Num

func (Sint32) RTE

func (o Sint32) RTE() IntNum

func (Sint32) RTN

func (o Sint32) RTN() IntNum

func (Sint32) Shl

func (o Sint32) Shl(n Num) Num

func (Sint32) Shr

func (o Sint32) Shr(n Num) Num

func (Sint32) String

func (o Sint32) String() string

func (Sint32) Sub

func (o Sint32) Sub(n Num) Num

type Sint64

type Sint64 int64 // fixnum

func (Sint64) Add

func (o Sint64) Add(n Num) Num

func (Sint64) Cmp

func (o Sint64) Cmp(n Num) int

func (Sint64) Div

func (o Sint64) Div(n Num) Num

func (Sint64) Equal

func (o Sint64) Equal(n Any) bool

func (Sint64) GetHash

func (o Sint64) GetHash() uintptr

func (Sint64) GetNumberType

func (o Sint64) GetNumberType() int

func (Sint64) GetType

func (o Sint64) GetType() int

func (Sint64) MakePolar

func (o Sint64) MakePolar(n RealNum) ComplexNum

func (Sint64) MakeRect

func (o Sint64) MakeRect(n RealNum) ComplexNum

func (Sint64) Mod

func (o Sint64) Mod(n Num) Num

func (Sint64) Mul

func (o Sint64) Mul(n Num) Num

func (Sint64) RTE

func (o Sint64) RTE() IntNum

func (Sint64) RTN

func (o Sint64) RTN() IntNum

func (Sint64) Shl

func (o Sint64) Shl(n Num) Num

func (Sint64) Shr

func (o Sint64) Shr(n Num) Num

func (Sint64) String

func (o Sint64) String() string

func (Sint64) Sub

func (o Sint64) Sub(n Num) Num

type Sint8

type Sint8 int8

exact

func (Sint8) Equal

func (o Sint8) Equal(a Any) bool

func (Sint8) GetHash

func (o Sint8) GetHash() uintptr

func (Sint8) GetNumberType

func (o Sint8) GetNumberType() int

func (Sint8) GetType

func (o Sint8) GetType() int

base numbers

type State

type State func(*Lexer) State

[AJR] Yes, I watched Rob Pike

type Suint16

type Suint16 uint16

func (Suint16) Equal

func (o Suint16) Equal(a Any) bool

func (Suint16) GetHash

func (o Suint16) GetHash() uintptr

func (Suint16) GetNumberType

func (o Suint16) GetNumberType() int

func (Suint16) GetType

func (o Suint16) GetType() int

type Suint32

type Suint32 uint32

func (Suint32) Equal

func (o Suint32) Equal(a Any) bool

func (Suint32) GetHash

func (o Suint32) GetHash() uintptr

func (Suint32) GetNumberType

func (o Suint32) GetNumberType() int

func (Suint32) GetType

func (o Suint32) GetType() int

type Suint64

type Suint64 uint64

func (Suint64) Equal

func (o Suint64) Equal(a Any) bool

func (Suint64) GetHash

func (o Suint64) GetHash() uintptr

func (Suint64) GetNumberType

func (o Suint64) GetNumberType() int

func (Suint64) GetType

func (o Suint64) GetType() int

type Suint8

type Suint8 uint8

func (Suint8) Equal

func (o Suint8) Equal(a Any) bool

func (o Sint32) Equal(a Any) bool { return false } func (o Sint64) Equal(a Any) bool { return false }

func (Suint8) GetHash

func (o Suint8) GetHash() uintptr

func (Suint8) GetNumberType

func (o Suint8) GetNumberType() int

func (Suint8) GetType

func (o Suint8) GetType() int

type TIPort

type TIPort interface {
	io.RuneReader
	RunePeeker
	LineReader
}

type TOPort

type TOPort interface {
	RunesWriter
}

type TPort

type TPort interface {
	TIPort
	TOPort
}

type Transformer

type Transformer interface {
	// (syntax).Transform(keyword, expression, environment)
	Transform(Any, Any, *Env) Any
}

type TrigNum

type TrigNum interface {
	Num
	ArcCos() Num
	ArcSin() Num
	ArcTan(Num) Num
	Cos() Num
	Sin() Num
	Tan() Num
	Sqrt() Num
	Pow(Num) Num
	Log(Num) Num
	Exp() Num
	Ln() Num
}

Directories

Path Synopsis
cmd
ds
* Droscheme - a Scheme implementation * Copyright © 2012 Andrew Robbins, Daniel Connelly * * This program is free software: it is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or * FITNESS FOR A PARTICULAR PURPOSE.
* Droscheme - a Scheme implementation * Copyright © 2012 Andrew Robbins, Daniel Connelly * * This program is free software: it is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or * FITNESS FOR A PARTICULAR PURPOSE.

Jump to

Keyboard shortcuts

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