http://www.perlmonks.org?node_id=1011782


in reply to XML::Parser XML validation

The parser cannot know how to fix the first error it finds. The other errors, therefore, might lack information value. Consider the following document:
<r> <a> <b> <c> </b> </a> </r>
The problem is the missing </c>. But the parser might tell you:
Start and end tag mismatch: c and b, line 5. Start and end tag mismatch: b and a, line 6. Start and end tag mismatch: a and r, line 7. Unexpected end of the document, line 7.
BTW, that's roughly what xmllint would tell you.
لսႽ† ᥲᥒ⚪⟊Ⴙᘓᖇ Ꮅᘓᖇ⎱ Ⴙᥲ𝇋ƙᘓᖇ