check for unterminated strings and comments