starlarkeval

package
v0.0.0-...-2e562ea Latest Latest
Warning

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

Go to latest
Published: Dec 18, 2023 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ConvCommentList

func ConvCommentList(list []syntax.Comment, txt string) []build.Comment

func ConvComments

func ConvComments(c *syntax.Comments) build.Comments

func ConvExpr

func ConvExpr(e syntax.Expr) build.Expr

func ConvExprs

func ConvExprs(list []syntax.Expr) []build.Expr

func ConvFile

func ConvFile(f *syntax.File) *build.File

func ConvStmt

func ConvStmt(stmt syntax.Stmt) build.Expr

func ConvStmts

func ConvStmts(list []syntax.Stmt) []build.Expr

func ConvValue

func ConvValue(value starlark.Value) build.Expr

Types

type Interpreter

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

func NewInterpreter

func NewInterpreter(reporter Reporter) *Interpreter

func (*Interpreter) Exec

func (i *Interpreter) Exec(filename string, src io.Reader) error

func (*Interpreter) GetGlobal

func (i *Interpreter) GetGlobal(name string) starlark.Value

type Reporter

type Reporter func(format string, args ...interface{})

Reporter is implemented by *testing.T.

Jump to

Keyboard shortcuts

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