error

package
v0.5.0-beta Latest Latest
Warning

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

Go to latest
Published: Apr 29, 2022 License: GPL-2.0 Imports: 0 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Error

type Error struct {
	ErrorType ErrorType
	TypeName  string
	Location  Location
	Message   string
}

func NewError

func NewError(errorType ErrorType, location Location, message string) *Error

type ErrorType

type ErrorType uint8
const (
	SyntaxError ErrorType = iota
	TypeError
	ReferenceError
	ValueError
	RuntimeError
)

type Location

type Location struct {
	Filename string
	Line     uint
	Column   uint
	Index    uint
}

func NewLocation

func NewLocation(filename string) Location

func (*Location) Advance

func (self *Location) Advance(newline bool)

Jump to

Keyboard shortcuts

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