Documentation ¶
Overview ¶
Package file encapsulates the file abstractions used by the ast & parser.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type File ¶
type File struct {
// contains filtered or unexported fields
}
type FileSet ¶
type FileSet struct {
// contains filtered or unexported fields
}
A FileSet represents a set of source files.
func (*FileSet) AddFile ¶
AddFile adds a new file with the given filename and src.
This an internal method, but exported for cross-package use.
type Idx ¶
type Idx int
Idx is a compact encoding of a source position within a file set. It can be converted into a Position for a more convenient, but much larger, representation.
type Position ¶
type Position struct { Filename string // The filename where the error occurred, if any Line int // The line number, starting at 1 Column int // The column number, starting at 1 (The character count) }
Position describes an arbitrary source position including the filename, line, and column location.
Click to show internal directories.
Click to hide internal directories.