Incomplete port of the lexer