| 175 |
#$self->{level} |
#$self->{level} |
| 176 |
#$self->{set_nc} |
#$self->{set_nc} |
| 177 |
#$self->{parse_error} |
#$self->{parse_error} |
| 178 |
|
#$self->{is_xml} (if XML) |
| 179 |
|
|
| 180 |
$self->{state} = DATA_STATE; # MUST |
$self->{state} = DATA_STATE; # MUST |
| 181 |
#$self->{s_kwd}; # state keyword - initialized when used |
#$self->{s_kwd}; # state keyword - initialized when used |
| 541 |
|
|
| 542 |
$self->{ct} |
$self->{ct} |
| 543 |
= {type => START_TAG_TOKEN, |
= {type => START_TAG_TOKEN, |
| 544 |
tag_name => chr ($self->{nc} + 0x0020), |
tag_name => chr ($self->{nc} + ($self->{is_xml} ? 0 : 0x0020)), |
| 545 |
line => $self->{line_prev}, |
line => $self->{line_prev}, |
| 546 |
column => $self->{column_prev}}; |
column => $self->{column_prev}}; |
| 547 |
$self->{state} = TAG_NAME_STATE; |
$self->{state} = TAG_NAME_STATE; |
| 660 |
|
|
| 661 |
$self->{ct} |
$self->{ct} |
| 662 |
= {type => END_TAG_TOKEN, |
= {type => END_TAG_TOKEN, |
| 663 |
tag_name => chr ($self->{nc} + 0x0020), |
tag_name => chr ($self->{nc} + ($self->{is_xml} ? 0 : 0x0020)), |
| 664 |
line => $l, column => $c}; |
line => $l, column => $c}; |
| 665 |
$self->{state} = TAG_NAME_STATE; |
$self->{state} = TAG_NAME_STATE; |
| 666 |
|
|
| 851 |
} elsif (0x0041 <= $self->{nc} and |
} elsif (0x0041 <= $self->{nc} and |
| 852 |
$self->{nc} <= 0x005A) { # A..Z |
$self->{nc} <= 0x005A) { # A..Z |
| 853 |
|
|
| 854 |
$self->{ct}->{tag_name} .= chr ($self->{nc} + 0x0020); |
$self->{ct}->{tag_name} |
| 855 |
|
.= chr ($self->{nc} + ($self->{is_xml} ? 0 : 0x0020)); |
| 856 |
# start tag or end tag |
# start tag or end tag |
| 857 |
## Stay in this state |
## Stay in this state |
| 858 |
|
|
| 974 |
$self->{nc} <= 0x005A) { # A..Z |
$self->{nc} <= 0x005A) { # A..Z |
| 975 |
|
|
| 976 |
$self->{ca} |
$self->{ca} |
| 977 |
= {name => chr ($self->{nc} + 0x0020), |
= {name => chr ($self->{nc} + ($self->{is_xml} ? 0 : 0x0020)), |
| 978 |
value => '', |
value => '', |
| 979 |
line => $self->{line}, column => $self->{column}}; |
line => $self->{line}, column => $self->{column}}; |
| 980 |
$self->{state} = ATTRIBUTE_NAME_STATE; |
$self->{state} = ATTRIBUTE_NAME_STATE; |
| 1135 |
} elsif (0x0041 <= $self->{nc} and |
} elsif (0x0041 <= $self->{nc} and |
| 1136 |
$self->{nc} <= 0x005A) { # A..Z |
$self->{nc} <= 0x005A) { # A..Z |
| 1137 |
|
|
| 1138 |
$self->{ca}->{name} .= chr ($self->{nc} + 0x0020); |
$self->{ca}->{name} |
| 1139 |
|
.= chr ($self->{nc} + ($self->{is_xml} ? 0 : 0x0020)); |
| 1140 |
## Stay in the state |
## Stay in the state |
| 1141 |
|
|
| 1142 |
if ($self->{char_buffer_pos} < length $self->{char_buffer}) { |
if ($self->{char_buffer_pos} < length $self->{char_buffer}) { |
| 1280 |
$self->{nc} <= 0x005A) { # A..Z |
$self->{nc} <= 0x005A) { # A..Z |
| 1281 |
|
|
| 1282 |
$self->{ca} |
$self->{ca} |
| 1283 |
= {name => chr ($self->{nc} + 0x0020), |
= {name => chr ($self->{nc} + ($self->{is_xml} ? 0 : 0x0020)), |
| 1284 |
value => '', |
value => '', |
| 1285 |
line => $self->{line}, column => $self->{column}}; |
line => $self->{line}, column => $self->{column}}; |
| 1286 |
$self->{state} = ATTRIBUTE_NAME_STATE; |
$self->{state} = ATTRIBUTE_NAME_STATE; |
| 2013 |
} |
} |
| 2014 |
|
|
| 2015 |
redo A; |
redo A; |
| 2016 |
} elsif ($self->{insertion_mode} & IN_FOREIGN_CONTENT_IM and |
} elsif ((($self->{insertion_mode} & IN_FOREIGN_CONTENT_IM and |
| 2017 |
$self->{open_elements}->[-1]->[1] & FOREIGN_EL and |
$self->{open_elements}->[-1]->[1] & FOREIGN_EL) or |
| 2018 |
|
$self->{is_xml}) and |
| 2019 |
$self->{nc} == 0x005B) { # [ |
$self->{nc} == 0x005B) { # [ |
| 2020 |
|
|
| 2021 |
$self->{state} = MD_CDATA_STATE; |
$self->{state} = MD_CDATA_STATE; |