Lexer changes

Mostly minor things that rebasing is becoming painful.
(or `let chars = s.chars().rev()` + `.next()` for the various `char_at`s below... maybe it doesn't matter since this is guaranteed to be ASCII (is it?).)