| 327 |
if ($self->{content_model_flag} eq 'RCDATA' or |
if ($self->{content_model_flag} eq 'RCDATA' or |
| 328 |
$self->{content_model_flag} eq 'CDATA') { |
$self->{content_model_flag} eq 'CDATA') { |
| 329 |
if (defined $self->{last_emitted_start_tag_name}) { |
if (defined $self->{last_emitted_start_tag_name}) { |
| 330 |
|
## NOTE: <http://krijnhoetmer.nl/irc-logs/whatwg/20070626#l-564> |
| 331 |
my @next_char; |
my @next_char; |
| 332 |
TAGNAME: for (my $i = 0; $i < length $self->{last_emitted_start_tag_name}; $i++) { |
TAGNAME: for (my $i = 0; $i < length $self->{last_emitted_start_tag_name}; $i++) { |
| 333 |
push @next_char, $self->{next_input_character}; |
push @next_char, $self->{next_input_character}; |
| 1019 |
} |
} |
| 1020 |
} |
} |
| 1021 |
|
|
| 1022 |
!!!parse-error (type => 'bogus comment open'); |
!!!parse-error (type => 'bogus comment'); |
| 1023 |
$self->{next_input_character} = shift @next_char; |
$self->{next_input_character} = shift @next_char; |
| 1024 |
!!!back-next-input-character (@next_char); |
!!!back-next-input-character (@next_char); |
| 1025 |
$self->{state} = 'bogus comment'; |
$self->{state} = 'bogus comment'; |
| 1488 |
|
|
| 1489 |
redo A; |
redo A; |
| 1490 |
} else { |
} else { |
| 1491 |
!!!parse-error (type => 'string after PUBLIC literal'); |
!!!parse-error (type => 'string after SYSTEM'); |
| 1492 |
$self->{state} = 'bogus DOCTYPE'; |
$self->{state} = 'bogus DOCTYPE'; |
| 1493 |
!!!next-input-character; |
!!!next-input-character; |
| 1494 |
redo A; |
redo A; |
| 1656 |
!!!parse-error (type => 'CR character reference'); |
!!!parse-error (type => 'CR character reference'); |
| 1657 |
$code = 0x000A; |
$code = 0x000A; |
| 1658 |
} elsif (0x80 <= $code and $code <= 0x9F) { |
} elsif (0x80 <= $code and $code <= 0x9F) { |
| 1659 |
!!!parse-error (type => sprintf 'c1 entity:U+%04X', $code); |
!!!parse-error (type => sprintf 'C1 character reference:U+%04X', $code); |
| 1660 |
$code = $c1_entity_char->{$code}; |
$code = $c1_entity_char->{$code}; |
| 1661 |
} |
} |
| 1662 |
|
|
| 1691 |
!!!parse-error (type => 'CR character reference'); |
!!!parse-error (type => 'CR character reference'); |
| 1692 |
$code = 0x000A; |
$code = 0x000A; |
| 1693 |
} elsif (0x80 <= $code and $code <= 0x9F) { |
} elsif (0x80 <= $code and $code <= 0x9F) { |
| 1694 |
!!!parse-error (type => sprintf 'c1 entity:U+%04X', $code); |
!!!parse-error (type => sprintf 'C1 character reference:U+%04X', $code); |
| 1695 |
$code = $c1_entity_char->{$code}; |
$code = $c1_entity_char->{$code}; |
| 1696 |
} |
} |
| 1697 |
|
|
| 1745 |
if ($match > 0) { |
if ($match > 0) { |
| 1746 |
return {type => 'character', data => $value}; |
return {type => 'character', data => $value}; |
| 1747 |
} elsif ($match < 0) { |
} elsif ($match < 0) { |
| 1748 |
!!!parse-error (type => 'refc'); |
!!!parse-error (type => 'no refc'); |
| 1749 |
return {type => 'character', data => $value}; |
return {type => 'character', data => $value}; |
| 1750 |
} else { |
} else { |
| 1751 |
!!!parse-error (type => 'bare ero'); |
!!!parse-error (type => 'bare ero'); |
| 3435 |
!!!next-token; |
!!!next-token; |
| 3436 |
redo B; |
redo B; |
| 3437 |
} elsif ($self->{insertion_mode} eq 'in head noscript') { |
} elsif ($self->{insertion_mode} eq 'in head noscript') { |
| 3438 |
!!!parse-error (type => 'noscript in noscript'); |
!!!parse-error (type => 'in noscript:noscript'); |
| 3439 |
## Ignore the token |
## Ignore the token |
| 3440 |
redo B; |
redo B; |
| 3441 |
} else { |
} else { |
| 5026 |
} |
} |
| 5027 |
|
|
| 5028 |
if (defined $token->{tag_name}) { |
if (defined $token->{tag_name}) { |
| 5029 |
!!!parse-error (type => 'in frameset:'.$token->{tag_name}); |
!!!parse-error (type => 'in frameset:'.($token->{type} eq 'end tag' ? '/' : '').$token->{tag_name}); |
| 5030 |
} else { |
} else { |
| 5031 |
!!!parse-error (type => 'in frameset:#'.$token->{type}); |
!!!parse-error (type => 'in frameset:#'.$token->{type}); |
| 5032 |
} |
} |
| 5070 |
} |
} |
| 5071 |
|
|
| 5072 |
if (defined $token->{tag_name}) { |
if (defined $token->{tag_name}) { |
| 5073 |
!!!parse-error (type => 'after frameset:'.$token->{tag_name}); |
!!!parse-error (type => 'after frameset:'.($token->{tag_name} eq 'end tag' ? '/' : '').$token->{tag_name}); |
| 5074 |
} else { |
} else { |
| 5075 |
!!!parse-error (type => 'after frameset:#'.$token->{type}); |
!!!parse-error (type => 'after frameset:#'.$token->{type}); |
| 5076 |
} |
} |
| 5120 |
redo B; |
redo B; |
| 5121 |
} elsif ($token->{type} eq 'start tag' or |
} elsif ($token->{type} eq 'start tag' or |
| 5122 |
$token->{type} eq 'end tag') { |
$token->{type} eq 'end tag') { |
| 5123 |
!!!parse-error (type => 'after html:'.$token->{tag_name}); |
!!!parse-error (type => 'after html:'.($token->{type} eq 'end tag' ? '/' : '').$token->{tag_name}); |
| 5124 |
$phase = 'main'; |
$phase = 'main'; |
| 5125 |
## reprocess |
## reprocess |
| 5126 |
redo B; |
redo B; |