implement-modules #43
@ -108,6 +108,7 @@ type Lexer interface {
|
|||||||
// NewLexer creates a new default lexer that reads from the given reader. The
|
// NewLexer creates a new default lexer that reads from the given reader. The
|
||||||
// filename parameter is used for token locations and error messages.
|
// filename parameter is used for token locations and error messages.
|
||||||
func NewLexer (filename string, reader io.Reader) (Lexer, error) {
|
func NewLexer (filename string, reader io.Reader) (Lexer, error) {
|
||||||
|
// TODO: replace this function with LexReader and LexFile functions
|
||||||
lexer := &fsplLexer {
|
lexer := &fsplLexer {
|
||||||
filename: filename,
|
filename: filename,
|
||||||
lineScanner: bufio.NewScanner(reader),
|
lineScanner: bufio.NewScanner(reader),
|
||||||
|
Loading…
Reference in New Issue
Block a user