From 562a9da820a55290c4f72a31439566ebe2f823b4 Mon Sep 17 00:00:00 2001 From: ConnorSkees <39542938+ConnorSkees@users.noreply.github.com> Date: Thu, 2 Apr 2020 02:23:48 -0400 Subject: [PATCH] handle backtick in selector --- src/selector.rs | 1 + tests/error.rs | 1 + 2 files changed, 2 insertions(+) diff --git a/src/selector.rs b/src/selector.rs index a94756d..4c8eaa7 100644 --- a/src/selector.rs +++ b/src/selector.rs @@ -334,6 +334,7 @@ impl<'a> SelectorParser<'a> { c if c.is_control() => { return Err("expected selector.".into()); } + '`' => return Err("expected selector.".into()), _ => todo!("unimplemented selector"), }; } diff --git a/tests/error.rs b/tests/error.rs index 0d89f8a..3c052c5 100644 --- a/tests/error.rs +++ b/tests/error.rs @@ -52,3 +52,4 @@ error!( control_character_starts_selector_inner, "a{l {color: foo;}}", "Error: expected selector." ); +error!(backtick_in_selector, "a`{}", "Error: expected selector.");