ast

package
v1.0.1 Latest Latest
Warning

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

Go to latest
Published: May 14, 2024 License: Apache-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Attrib

type Attrib interface{}

type Identifier

type Identifier struct {
	Name          *token.Token
	ParserContext *ParserContext
}

Simple type that will convey both kinds of context.

func NewIdentifier

func NewIdentifier(name Attrib, context interface{}) (*Identifier, error)

type LexicalContext

type LexicalContext struct {
	SourceFile     string
	ForbiddenWords []string
}

Demonstrates how Lexical and Parser context might differ.

func (*LexicalContext) Source

func (lc *LexicalContext) Source() string

Source implements the lexer.Sourcer interface.

type ParserContext

type ParserContext struct {
	ImportedFiles        []*token.Token // files and where we imported them from
	ExtensionToForbidden map[string]string
	Visitors             []string
	CallbackFn           func()
}

Jump to

Keyboard shortcuts

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