parser

package
v0.0.0-...-228c761 Latest Latest
Warning

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

Go to latest
Published: Sep 22, 2024 License: MIT Imports: 11 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ParseFile

func ParseFile(src string) (*ast.Program, error)

ParseFile parses the source code of a single JavaScript/ECMAScript source file and returns the corresponding ast.Program node.

Types

type ErrorList

type ErrorList []error

ErrorList is a list of *Errors.

func (*ErrorList) Add

func (e *ErrorList) Add(msg string)

Add adds an Error with given position and message to an ErrorList.

func (*ErrorList) Err

func (e *ErrorList) Err() error

Err returns an error equivalent to this ErrorList. If the list is empty, Err returns nil.

func (*ErrorList) Error

func (e *ErrorList) Error() string

Error implements the Error interface.

Jump to

Keyboard shortcuts

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