File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -302,7 +302,6 @@ export function parse(
302302 S . charCodeAt ( pos + 8 ) === LBRACKET &&
303303 S . substring ( pos + 3 , pos + 8 ) . toLowerCase ( ) === 'cdata'
304304 ) {
305- // cdata
306305 const cdataEndIndex = S . indexOf ( ']]>' , pos ) ;
307306 if ( cdataEndIndex === - 1 ) {
308307 if ( strict ) throw strictError ( 'Unclosed CDATA section' ) ;
@@ -635,7 +634,6 @@ export function parse(
635634 if ( strict && ! S [ pos ] ) {
636635 throw strictError ( `Unclosed tag <${ tagName } >` ) ;
637636 }
638- // optional parsing of children
639637 // Self-closing: explicit />, processing instruction ?>, or declaration <!...>
640638 if (
641639 S . charCodeAt ( pos - 1 ) !== SLASH &&
Original file line number Diff line number Diff line change @@ -353,17 +353,14 @@ export function saxEngine(options: SaxEngineOptions = {}): SaxEngineParser {
353353 // OPEN_TAG_NAME — batch scan for end of name
354354 // ==================================================================
355355 case State . OPEN_TAG_NAME : {
356- // Scan ahead for end of tag name
357356 let j = i ;
358357 while ( j < chunkLength ) {
359358 const charCode = chunk . charCodeAt ( j ) ;
360359 if ( isNameEnd ( charCode ) ) break ;
361360 j ++ ;
362361 }
363- // Accumulate what we scanned
364362 if ( j > i ) tagName += chunk . substring ( i , j ) ;
365363 if ( j >= chunkLength ) {
366- // Tag name continues in next chunk
367364 i = chunkLength ;
368365 continue ;
369366 }
You can’t perform that action at this time.
0 commit comments