Documentation ¶
Index ¶
- func Eval(ctx context.Context, source string, options ...Option) (object.Object, error)
- type Option
- func WithBuiltins(builtins map[string]object.Object) Option
- func WithCode(c *object.Code) Option
- func WithCompiler(c *compiler.Compiler) Option
- func WithDefaultBuiltins() Option
- func WithDefaultModules() Option
- func WithImporter(i importer.Importer) Option
- func WithInstructionOffset(offset int) Option
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Option ¶
type Option func(*cfg.RisorConfig)
func WithCompiler ¶
func WithDefaultBuiltins ¶
func WithDefaultBuiltins() Option
func WithDefaultModules ¶
func WithDefaultModules() Option
func WithImporter ¶
func WithInstructionOffset ¶
Directories ¶
Path | Synopsis |
---|---|
Package ast defines abstract syntax tree types that represent Risor code.
|
Package ast defines abstract syntax tree types that represent Risor code. |
Package builtins defines the default set of builtin functions for Risor.
|
Package builtins defines the default set of builtin functions for Risor. |
cmd
|
|
risor-lsp
This package implements a Risor language server.
|
This package implements a Risor language server. |
risor-docs
Module
|
|
risor-modgen
Module
|
|
Package compiler is used to compile an Abstract Syntax Tree (AST) into its corresponding bytecode.
|
Package compiler is used to compile an Abstract Syntax Tree (AST) into its corresponding bytecode. |
examples
|
|
go/struct
Module
|
|
internal
|
|
tmpl
Package tmpl is used to parse Risor string templates.
|
Package tmpl is used to parse Risor string templates. |
Package lexer contains the code to lex input programs into a stream of tokens.
|
Package lexer contains the code to lex input programs into a stream of tokens. |
modules
|
|
bcrypt
Module
|
|
carbon
Module
|
|
cli
Module
|
|
gha
Module
|
|
jmespath
Module
|
|
kubernetes
Module
|
|
sql
Module
|
|
template
Module
|
|
vault
Module
|
|
Package object defines the standard set of object types in Risor.
|
Package object defines the standard set of object types in Risor. |
Package op defines the opcodes that are used in the Risor virtual machine.
|
Package op defines the opcodes that are used in the Risor virtual machine. |
Package parser is used to parse an input program from its tokens and produce an abstract syntax tree (AST) as output.
|
Package parser is used to parse an input program from its tokens and produce an abstract syntax tree (AST) as output. |
Package repl implements a read-eval-print-loop for Risor.
|
Package repl implements a read-eval-print-loop for Risor. |
tests
|
|
Package token defines the tokens that are produced when lexing Risor code.
|
Package token defines the tokens that are produced when lexing Risor code. |
Click to show internal directories.
Click to hide internal directories.