Documentation
¶
Index ¶
Constants ¶
View Source
const ( // IntegerObj name IntegerObj = "INTEGER" // BooleanObj name BooleanObj = "BOOLEAN" // NullObj name NullObj = "NULL" // ReturnValueObj name ReturnValueObj = "RETURN_VALUE" // ErrorObj name ErrorObj = "ERROR" // FunctionObj name FunctionObj = "FUNCTION" //StringObj name StringObj = "STRING" //BuiltinObj name BuiltinObj = "BUILTIN" // ArrayObj name ArrayObj = "ARRAY" // HashObj name HashObj = "HASH" )
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Boolean ¶
type Boolean struct {
Value bool
}
Boolean data type
type BuiltinFunction ¶
BuiltinFunction defines an inbuilt function
type Environment ¶
type Environment struct {
// contains filtered or unexported fields
}
Environment holds the values in global
func NewEnclosedEnvironment ¶
func NewEnclosedEnvironment(outer *Environment) *Environment
NewEnclosedEnvironment creates a new Enclosed env
func NewEnvironment ¶
func NewEnvironment() *Environment
NewEnvironment creates a new Environment with a map
type Error ¶
type Error struct {
Message string
}
Error data type
type Function ¶
type Function struct {
Parameters []*ast.Identifier
Body *ast.BlockStatement
Env *Environment
}
Function data type
type Hashable ¶
type Hashable interface {
HashKey() HashKey
}
Hashable defines methods for elements that can be used as HashKeys
type Integer ¶
type Integer struct {
Value int64
}
Integer data type
type ReturnValue ¶
type ReturnValue struct {
Value Object
}
ReturnValue data type
func (*ReturnValue) Inspect ¶
func (rv *ReturnValue) Inspect() string
Inspect returns the Return value string format
Click to show internal directories.
Click to hide internal directories.