aboutsummaryrefslogtreecommitdiff
path: root/src/default_emitter.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/default_emitter.rs')
-rw-r--r--src/default_emitter.rs16
1 files changed, 0 insertions, 16 deletions
diff --git a/src/default_emitter.rs b/src/default_emitter.rs
index c957b20..9d5ab52 100644
--- a/src/default_emitter.rs
+++ b/src/default_emitter.rs
@@ -11,22 +11,6 @@ use crate::Emitter;
use crate::Error;
/// The default implementation of [`Emitter`], used to produce tokens.
-///
-/// # Warning
-///
-/// * Using the DefaultEmitter without calling [`Tokenizer::set_state`]
-/// results in wrong state transitions:
-///
-/// ```
-/// # use html5tokenizer::{DefaultEmitter, Event, Tokenizer, Token};
-/// let emitter = DefaultEmitter::default();
-/// let html = "<script><b>";
-/// let mut tokens = Tokenizer::new(html, emitter).flatten();
-/// assert!(matches!(tokens.next().unwrap(), Event::Token(Token::StartTag(tag)) if tag.name == "script"));
-/// assert!(matches!(tokens.next().unwrap(), Event::Token(Token::StartTag(tag)) if tag.name == "b"));
-/// ```
-///
-/// [`Tokenizer::set_state`]: crate::Tokenizer::set_state
pub struct DefaultEmitter<O = NoopOffset> {
current_characters: String,
current_token: Option<Token<O>>,