core

package
v0.4.1 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func Append

func Append(_ *object.Environment, args ...object.Object) object.Object

Append returns a new array with value pushed onto the end of array.

func Args

func Args(_ *object.Environment, args ...object.Object) object.Object

Args args() Returns an array of command-line options passed to the program

func Bool

func Bool(_ *object.Environment, args ...object.Object) object.Object

Bool converts value to a bool

func Delete

func Delete(_ *object.Environment, args ...object.Object) object.Object

Delete a given hash-key

func Exit

func Exit(_ *object.Environment, args ...object.Object) object.Object

Exit exit([status]) Exits the program immediately with the optional status or 0

func Float

func Float(_ *object.Environment, args ...object.Object) object.Object

Float converts decimal value str to float. If value is invalid returns null

func Input

func Input(_ *object.Environment, args ...object.Object) object.Object

Input reads a line from standard input optionally printing prompt. input([prompt]) prints the prompt.

func Int

func Int(_ *object.Environment, args ...object.Object) object.Object

Int converts decimal value str to int. If value is invalid returns null

func Keys

func Keys(_ *object.Environment, args ...object.Object) object.Object

Keys returns the keys of the specified hash

func Len

func Len(_ *object.Environment, args ...object.Object) object.Object

Len len(iterable) Returns the length of the iterable (str, array or hash).

func Print

func Print(env *object.Environment, args ...object.Object) object.Object

Print output a string to stdout

func Printf

func Printf(env *object.Environment, args ...object.Object) object.Object

Printf ...

func Sprintf

func Sprintf(_ *object.Environment, args ...object.Object) object.Object

Sprintf is the implementation of our `sprintf` function.

func Str

func Str(_ *object.Environment, args ...object.Object) object.Object

Str returns the string representation of value.

func TypeOf

func TypeOf(_ *object.Environment, args ...object.Object) object.Object

TypeOf returns a str denoting the type of value: nil, bool, int, float, str, array, hash, or fn.

Types

This section is empty.

Jump to

Keyboard shortcuts

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