Reimplemented lexer with alex.