rewrote some lexing functions
lost on parsing