Versions in this module Expand all Collapse all v1 v1.3.2 Jan 7, 2017 v1.3.1 Sep 22, 2016 v1.3.0 Sep 19, 2016 v1.2.0 Jun 23, 2016 v0 v0.4.0 Jun 23, 2016 v0.3.0 Mar 16, 2016 Changes in this version + const HighestPrec + const LowestPrec + const UnaryPrec + type File struct + func (f *File) AddLine(offset int) + func (f *File) AddLineInfo(offset int, filename string, line int) + func (f *File) Base() int + func (f *File) Line(p Pos) int + func (f *File) LineCount() int + func (f *File) MergeLine(line int) + func (f *File) Name() string + func (f *File) Offset(p Pos) int + func (f *File) Pos(offset int) Pos + func (f *File) Position(p Pos) (pos Position) + func (f *File) PositionFor(p Pos, adjusted bool) (pos Position) + func (f *File) SetLines(lines []int) bool + func (f *File) SetLinesForContent(content []byte) + func (f *File) Size() int + type FileSet struct + func NewFileSet() *FileSet + func (s *FileSet) AddFile(filename string, base, size int) *File + func (s *FileSet) Base() int + func (s *FileSet) File(p Pos) (f *File) + func (s *FileSet) Iterate(f func(*File) bool) + func (s *FileSet) Position(p Pos) (pos Position) + func (s *FileSet) PositionFor(p Pos, adjusted bool) (pos Position) + func (s *FileSet) Read(decode func(interface{}) error) error + func (s *FileSet) Write(encode func(interface{}) error) error + type Pos int + const NoPos + func (p Pos) IsValid() bool + type Position struct + Column int + Filename string + Line int + Offset int + func (pos *Position) IsValid() bool + func (pos Position) String() string + type Token int + const ADD + const ADD_ASSIGN + const AND + const AND_ASSIGN + const AND_NOT + const AND_NOT_ASSIGN + const ARROW + const ASSIGN + const BREAK + const CASE + const CHAN + const CHAR + const COLON + const COMMA + const COMMENT + const CONST + const CONTINUE + const DEC + const DEFAULT + const DEFER + const DEFINE + const ELLIPSIS + const ELSE + const EOF + const EQL + const FALLTHROUGH + const FLOAT + const FOR + const FUNC + const GEQ + const GO + const GOTO + const GTR + const IDENT + const IF + const ILLEGAL + const IMAG + const IMPORT + const INC + const INT + const INTERFACE + const LAND + const LBRACE + const LBRACK + const LEQ + const LOR + const LPAREN + const LSS + const MAP + const MUL + const MUL_ASSIGN + const NEQ + const NOT + const OR + const OR_ASSIGN + const PACKAGE + const PERIOD + const QUO + const QUO_ASSIGN + const RANGE + const RBRACE + const RBRACK + const REM + const REM_ASSIGN + const RETURN + const RPAREN + const SELECT + const SEMICOLON + const SHL + const SHL_ASSIGN + const SHR + const SHR_ASSIGN + const STRING + const STRUCT + const SUB + const SUB_ASSIGN + const SWITCH + const TYPE + const VAR + const XOR + const XOR_ASSIGN + func Lookup(ident string) Token + func (op Token) Precedence() int + func (tok Token) IsKeyword() bool + func (tok Token) IsLiteral() bool + func (tok Token) IsOperator() bool + func (tok Token) String() string