aboutsummaryrefslogtreecommitdiff
path: root/src/tokenizer/machine.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/tokenizer/machine.rs')
-rw-r--r--src/tokenizer/machine.rs32
1 files changed, 16 insertions, 16 deletions
diff --git a/src/tokenizer/machine.rs b/src/tokenizer/machine.rs
index faf1ea8..944eb01 100644
--- a/src/tokenizer/machine.rs
+++ b/src/tokenizer/machine.rs
@@ -114,14 +114,14 @@ where
}
None => Ok(ControlToken::Eof),
},
- State::RcData => match slf.read_char()? {
+ State::Rcdata => match slf.read_char()? {
Some('&') => {
- slf.return_state = Some(State::RcData);
+ slf.return_state = Some(State::Rcdata);
slf.state = State::CharacterReference;
Ok(ControlToken::Continue)
}
Some('<') => {
- slf.state = State::RcDataLessThanSign;
+ slf.state = State::RcdataLessThanSign;
Ok(ControlToken::Continue)
}
Some('\0') => {
@@ -135,7 +135,7 @@ where
}
None => Ok(ControlToken::Eof),
},
- State::RawText => match slf.read_char()? {
+ State::Rawtext => match slf.read_char()? {
Some('<') => {
slf.state = State::RawTextLessThanSign;
Ok(ControlToken::Continue)
@@ -167,7 +167,7 @@ where
}
None => Ok(ControlToken::Eof),
},
- State::PlainText => match slf.read_char()? {
+ State::Plaintext => match slf.read_char()? {
Some('\0') => {
slf.emit_error(Error::UnexpectedNullCharacter);
slf.emit_char_for_source_char('\u{fffd}', '\0');
@@ -270,34 +270,34 @@ where
Ok(ControlToken::Eof)
}
},
- State::RcDataLessThanSign => match slf.read_char()? {
+ State::RcdataLessThanSign => match slf.read_char()? {
Some('/') => {
slf.temporary_buffer.clear();
- slf.state = State::RcDataEndTagOpen;
+ slf.state = State::RcdataEndTagOpen;
Ok(ControlToken::Continue)
}
c => {
slf.emit_char('<');
- slf.state = State::RcData;
+ slf.state = State::Rcdata;
slf.unread_char(c);
Ok(ControlToken::Continue)
}
},
- State::RcDataEndTagOpen => match slf.read_char()? {
+ State::RcdataEndTagOpen => match slf.read_char()? {
Some(x) if x.is_ascii_alphabetic() => {
slf.init_end_tag();
- slf.state = State::RcDataEndTagName;
+ slf.state = State::RcdataEndTagName;
slf.unread_char(Some(x));
Ok(ControlToken::Continue)
}
c => {
slf.emit_chars(b"</");
- slf.state = State::RcData;
+ slf.state = State::Rcdata;
slf.unread_char(c);
Ok(ControlToken::Continue)
}
},
- State::RcDataEndTagName => match slf.read_char()? {
+ State::RcdataEndTagName => match slf.read_char()? {
Some(whitespace_pat!()) if slf.current_end_tag_is_appropriate() => {
slf.state = State::BeforeAttributeName;
Ok(ControlToken::Continue)
@@ -320,7 +320,7 @@ where
slf.emit_chars(b"</");
slf.flush_buffer_characters();
- slf.state = State::RcData;
+ slf.state = State::Rcdata;
slf.unread_char(c);
Ok(ControlToken::Continue)
}
@@ -333,7 +333,7 @@ where
}
c => {
slf.emit_char('<');
- slf.state = State::RawText;
+ slf.state = State::Rawtext;
slf.unread_char(c);
Ok(ControlToken::Continue)
}
@@ -347,7 +347,7 @@ where
}
c => {
slf.emit_chars(b"</");
- slf.state = State::RawText;
+ slf.state = State::Rawtext;
slf.unread_char(c);
Ok(ControlToken::Continue)
}
@@ -375,7 +375,7 @@ where
slf.emit_chars(b"</");
slf.flush_buffer_characters();
- slf.state = State::RawText;
+ slf.state = State::Rawtext;
slf.unread_char(c);
Ok(ControlToken::Continue)
}