Adding in more error checks in the lexer.