updated lexer to spec