XmlLexerResult — DOCTYPE token when ready, needMore otherwise.XmlLexerResult tryResumeDoctype() @safeResumes scanning a DOCTYPE declaration across chunk boundaries.
Tracks bracket depth (for internal subsets) and quote state to correctly handle `>` characters inside quoted strings or […] blocks. Produces a DOCTYPE token when the closing `>` is found at bracket depth 0.
XmlLexerResult — DOCTYPE token when ready, needMore otherwise.XmlException with UNEXPECTED_EOF if the stream ends before the
closing `>`.