func okState(l *lex.Lexer) lex.State { fmt.Println("okState") l.Emit(lex.ItemEOF) time.Sleep(10 * time.Millisecond) return nil }
func endState(l *lex.Lexer) lex.State { fmt.Println("endState") l.Emit(lex.ItemEOF) return nil }
func startState(l *lex.Lexer) lex.State { l.AcceptRun("abcdefghijklmnopqrstuvwxyz") l.Emit(alphas) return okState }