larker

package
v0.6.2 Latest Latest
Warning

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

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

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrLoadFailed           = errors.New("load failed")
	ErrExecFailed           = errors.New("exec failed")
	ErrMainFailed           = errors.New("failed to call main")
	ErrMainUnexpectedResult = errors.New("main returned unexpected result")
)
View Source
var ErrCycle = errors.New("import cycle detected")

Functions

This section is empty.

Types

type CacheEntry

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

type Context

type Context struct{}

func (*Context) Freeze

func (context *Context) Freeze()

func (*Context) Hash

func (context *Context) Hash() (uint32, error)

func (*Context) String

func (context *Context) String() string

func (*Context) Truth

func (context *Context) Truth() starlark.Bool

func (*Context) Type

func (context *Context) Type() string

type Larker

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

func New

func New(opts ...Option) *Larker

func (*Larker) Main

func (larker *Larker) Main(ctx context.Context, source string) (string, error)

type Loader

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

func NewLoader

func NewLoader(fs fs.FileSystem) *Loader

func (*Loader) LoadFunc

func (loader *Loader) LoadFunc() func(thread *starlark.Thread, module string) (starlark.StringDict, error)

type Option

type Option func(*Larker)

func WithFileSystem

func WithFileSystem(fs fs.FileSystem) Option

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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