diff options
Diffstat (limited to 'src')
-rw-r--r-- | src/compiler.rs | 2 | ||||
-rw-r--r-- | src/construct/character_reference.rs | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/src/compiler.rs b/src/compiler.rs index 2a3f101..6f0215c 100644 --- a/src/compiler.rs +++ b/src/compiler.rs @@ -374,7 +374,7 @@ pub fn compile(events: &[Event], codes: &[Code], options: &CompileOptions) -> St CharacterReferenceKind::Named => decode_named(ref_string), }; - buf_tail_mut(buffers).push(value); + buf_tail_mut(buffers).push(encode(&value)); character_reference_kind = None; } diff --git a/src/construct/character_reference.rs b/src/construct/character_reference.rs index ba2ad61..af9c02e 100644 --- a/src/construct/character_reference.rs +++ b/src/construct/character_reference.rs @@ -189,7 +189,7 @@ fn value(tokenizer: &mut Tokenizer, code: Code, info: Info) -> StateFnResult { if let Kind::Named = info.kind { if !CHARACTER_REFERENCE_NAMES.contains(&value.as_str()) { - return (State::Nok, Some(vec![code])); + return (State::Nok, None); } } |