Simplify loop conditionals for while loops in JsonReader and XmlReader.