func (s *Scanner) Errors() (warns []error, errs []error) {
	return s.warns, s.errs
}
Errors returns the errors and warns during a scan.
package parser
import (
	"bytes"
	"fmt"
	"strconv"
	"strings"
	"unicode"
	"unicode/utf8"
	"github.com/nooncall/shazam/mysql"
)
var _ = yyLexer(&Scanner{})
type Pos struct {
	Line   int
	Col    int
	Offset int
}
type Scanner struct {
	r   reader
	buf bytes.Buffer
	errs         []error
	warns        []error
	stmtStartPos int
	specialComment specialCommentScanner
	sqlMode mysql.SQLMode
	supportWindowFunc bool
	lastScanOffset int
}
type specialCommentScanner interface {
	scan() (tok int, pos Pos, lit string)
}
type mysqlSpecificCodeScanner struct {
	*Scanner
	Pos
}
func (s *mysqlSpecificCodeScanner) scan() (tok int, pos Pos, lit string) {
	tok, pos, lit = s.Scanner.scan()
	pos.Line += s.Pos.Line
	pos.Col += s.Pos.Col
	pos.Offset += s.Pos.Offset
	return
}
type optimizerHintScanner struct {
	*Scanner
	Pos
	end bool
}
func (s *optimizerHintScanner) scan() (tok int, pos Pos, lit string) {
	tok, pos, lit = s.Scanner.scan()
	pos.Line += s.Pos.Line
	pos.Col += s.Pos.Col
	pos.Offset += s.Pos.Offset
	if tok == 0 {
		if !s.end {
			tok = hintEnd
			s.end = true
		}
	}
	return
}