gosource

package
v0.0.0-...-b8e099b Latest Latest
Warning

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

Go to latest
Published: Aug 30, 2016 License: MIT Imports: 5 Imported by: 1

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Line

type Line struct {
	Num    int
	Tokens []Token
	// contains filtered or unexported fields
}

Line represents a line

func Parse

func Parse(filename string) ([]*Line, error)

Parse parses a single Go source file into a slice of Line

func (*Line) Add

func (l *Line) Add(t Token)

Add appends a token to the line.

type Token

type Token struct {
	Name, Text, Kind string
	Line             int
	// contains filtered or unexported fields
}

Token represents a token in a line

Jump to

Keyboard shortcuts

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