run

package
v0.0.0-...-1e04c87 Latest Latest
Warning

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

Go to latest
Published: Jun 10, 2018 License: MIT Imports: 15 Imported by: 0

Documentation

Overview

Package run provides a hook into the smoosh interpreter.

Index

Constants

View Source
const MONKEY_FACE = `` /* 273-byte string literal not displayed */

Variables

This section is empty.

Functions

This section is empty.

Types

type Runner

type Runner struct {
	Parse    bool
	Evaluate bool
	Format   bool
}

Runner can run a repl or a program

func NewRunner

func NewRunner() *Runner

NewRunner initializes a Runner

func (*Runner) Run

func (r *Runner) Run(rdr io.Reader, out io.Writer, stderr io.Writer) error

Run runs an io.Reader as a single program

func (*Runner) RunFile

func (r *Runner) RunFile(filename string, out io.Writer, stderr io.Writer) error

RunFile runs a file as a single program

func (*Runner) Start

func (r *Runner) Start(in io.Reader, out io.Writer, stderr io.Writer)

Start starts a line-by-line processor

Jump to

Keyboard shortcuts

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